2009-03-19 3 views
2

Mac OS X Leopard Server를 실행 중이고 해당 사용자의 홈 디렉토리를 지정하지 않고 새 사용자를 만들었습니다. 공개 키를 사용하여 해당 사용자를 인증 할 수 있습니까?홈 디렉토리가없는 사용자를위한 SSH 공개 키

나는 나의 이해이기 때문에이 사용자에 대한 홈 디렉토리를 생성하지 않으

~/.ssh/authorized_keys에 그 다음 그들을 로그인 할 수 있도록 해주는 사용자 그렇게되면 그것이 간다 홈 디렉토리가 알고 물리적 액세스가 주어진 경우.

업데이트 :이 사용자는 보안 FTP 연결 만 허용해야합니다. 로그인 셸을 /bin/false/으로 설정하면 원격 셸에서도 원격 셸에 연결할 수 없습니다.

답변

8

/etc/ssh/sshd_config 또는 컴퓨터에있는 위치를 편집하고 AuthorizedKeysFile 설정을 변경해야합니다.

AuthorizedKeysFile 
     Specifies the file that contains the public keys that can be used 
     for user authentication. AuthorizedKeysFile may contain tokens of 
     the form %T which are substituted during connection setup. The fol- 
     lowing tokens are defined: %% is replaced by a literal '%', %h is 
     replaced by the home directory of the user being authenticated, and 
     %u is replaced by the username of that user. After expansion, 
     AuthorizedKeysFile is taken to be an absolute path or one relative 
     to the user's home directory. The default is 
     ``.ssh/authorized_keys''. 

을하지만 사용자가 왜 가정하지 않고 (즉, 로그인 할 수 있습니다) :

워드 프로세서 말?

+0

내가 지정한 폴더로 SFTP 할 수 있기를 바랍니다. 하위 폴더에 SFTP를 chrooted. – matpie