0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

CentOS7 にて、空パスワードのユーザ作成

0
Posted at

1.はじめに

  • CentOS7 上に空パスワードのユーザを作成し、手元端末からログインできるようにするまでの手順メモ。
  • MacOS の物理媒体を用意。ターミナルから CentOS7 に対して、空パスワードユーザでログインできることを確認する。

2. 手順

  • まずはユーザの作成・暫定パスワードを設定
# useradd <作成したいユーザ名>
# passwd <上で作成したユーザ名>
ユーザー <上で作成したユーザ名> のパスワードを変更。
新しいパスワード: ******** 
新しいパスワードを再入力してください: *******
passwd: すべての認証トークンが正しく更新できました。
  • 上記で作成したユーザのパスワードを削除する。
# passwd -d <上で作成したユーザ名>
ユーザー <上で作成したユーザ名> のパスワードを削除。 
  • このままではまだログインできない(初期設定では、空パスワードのログインが許可されていない)。
    sshd の config ファイルを編集する。
# vi /etc/ssh/sshd_config 

※ 以下の箇所を「yes」に変更。
PermitEmptyPasswords yes
  • 上記編集後、sshd を再起動する。
# systemctl restart sshd

以上で、空パスワードでのユーザログインが実現できる。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?