この最終ステップでは、Metasploit コンソールを初めて起動し、初期設定プロセスを開始します。これには、ホストデータ、脆弱性、収集された証拠を含むプロジェクトに関する情報を保存するために Metasploit が使用するデータベースの設定が含まれます。
コンソールを起動するには、ターミナルで単にmsfconsoleと入力して Enter キーを押します。
msfconsole
Metasploit を初めて実行すると、初期設定ウィザードが表示されます。
** Welcome to Metasploit Framework Initial Setup **
Please answer a few questions to get started.
Would you like to use and setup a new database (recommended)?
データベース設定を続行するには、yesと入力して Enter キーを押します。
Would you like to use and setup a new database (recommended)? yes
Running the 'init' command for the database:
Creating database at /home/labex/.msf4/db
Creating db socket file at /tmp
Starting database at /home/labex/.msf4/db...waiting for server to start.... done
server started
success
Creating database users
Writing client authentication configuration file /home/labex/.msf4/db/pg_hba.conf
Stopping database at /home/labex/.msf4/db
Starting database at /home/labex/.msf4/db...waiting for server to start.... done
server started
success
Creating initial database schema
Database initialization successful
Database initialization successful
** Metasploit Framework Initial Setup Complete **
セットアップが完了すると、おなじみの Metasploit のバナーとプロンプトが表示されます。
Metasploit tip: Display the Framework log using the log command, learn
more with help log
Call trans opt: received. 2-19-98 13:24:18 REC:Loc
Trace program: running
wake up, Neo...
the matrix has you
follow the white rabbit.
knock, knock, Neo.
(`. ,-,
` `. ,;' /
`. ,'/ .'
`. X /.'
.-;--''--.._` ` (
.' / `
, ` ' Q '
, , `._ \
,.| ' `-.;_'
: . ` ; ` ` --,.._;
' ` , ) .'
`._ , ' /_
; ,''-,;' ``-
``-..__``--`
https://metasploit.com
=[ metasploit v6.4.x-dev- ]
+ -- --=[ 2,564 exploits - 1,315 auxiliary - 1,680 payloads ]
+ -- --=[ 431 post - 49 encoders - 13 nops - 9 evasion ]
Metasploit Documentation: https://docs.metasploit.com/
The Metasploit Framework is a Rapid7 Open Source Project
msf >
データベースが正しく接続されていることを確認するには、Metasploit コンソール内でdb_statusコマンドを実行します。
db_status
期待される出力は次のとおりです。
[*] Connected to msf. Connection type: postgresql.
これにより、Metasploit インスタンスが PostgreSQL データベースに正常に接続されていることが確認されます。Metasploit コンソールを終了するには、単にexitと入力します。
exit