
おそらく愚かな質問ですが、FTP サーバーに接続するときに、アカウントのオプションが表示されることがあります。ユーザー名と比較して、これはどのような意味を持つのでしょうか?
たとえば、Apache FTP クライアントからのこのメソッドを参照してください。
/**
* Login to the FTP server using the provided username, password,
* and account. If no account is required by the server, only
* the username and password, the account information is not used.
*
* @param username The username to login under.
* @param password The password to use.
* @param account The account to use.
* @return True if successfully completed, false if not.
* @throws FTPConnectionClosedException
* If the FTP server prematurely closes the connection as a result
* of the client being idle or some other reason causing the server
* to send FTP reply code 421. This exception may be caught either
* as an IOException or independently as itself.
* @throws IOException If an I/O error occurs while either sending a
* command to the server or receiving a reply from the server.
*/
public boolean login(final String username, final String password, final String account)
throws IOException
{
....
}
答え1
「アカウント」は、特定のシステムではほとんど使用されません。使用する必要がある場合はわかりますが、ほとんどの場合はわかりません。おそらく、古いものでしょう。結局のところ、FTPRFC959 の翻訳「アカウント」機能を定義するのは 1985 年のものです。
FTP RFC 959 では、ACCT
(account) コマンドについて次のように漠然と述べられています。
引数フィールドは、ユーザーのアカウントを識別する Telnet 文字列です。一部のサイトではログインにアカウントが必要であり、他のサイトではファイルの保存などの特定のアクセスにのみアカウントが必要な場合があるため、このコマンドは必ずしも USER コマンドに関連しているわけではありません。後者の場合、コマンドはいつでも到着する可能性があります。