  We present three-dimensional solutions of the magnetohydrostatic equations in
the co-rotating frame of reference outside a magnetized rigidly rotating
cylinder. We make no symmetry assumption for the magnetic field, but to be able
to make analytical progress we neglect outflows and specify a particular form
for the current density. The magnetohydrostatic equations can then be reduced
to a single linear partial differential equation for a pseudo-potential $U$,
from which the magnetic field can be calculated by differentiation. The
equation for $U$ can be solved by standard methods. The solutions can also be
used to determine the plasma pressure, density and temperature as functions of
all three spatial coordinates. Despite the obvious limitations of this
approach, it can for example be used as a simple tool to create
three-dimensional models for the closed field line regions of rotating
magnetospheres without rotational symmetry.
