def write_private_key(self, file_obj, password=None):
raise Exception('<STR_LIT>')<EOL>
Write private key contents into a file (or file-like) object.  If the
password is not C{None}, the key is encrypted before writing.

@param file_obj: the file object to write into
@type file_obj: file
@param password: an optional password to use to encrypt the key
@type password: str

@raise IOError: if there was an error writing to the file
@raise SSHException: if the key is invalid