pw utility is a command-line utility for the FreeBSD which provides ability to locking or unlocking FreeBSD user accounts.
FreeBSD locking an account command
Syntax:
pw lock <username>
Example
Lock user account named vivek. Login as a root user and type following command:
# pw lock xyz
FreeBSD unlocking an account command
Syntax:
pw unlock <{username>
Example
Unlock user account named vivek. Login as the root user and type the following command:
# pw unlock xyz