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 3 years have passed since last update.

2021_8.1.0.1 備忘録:Snortインストール編

Last updated at Posted at 2021-08-25

概要:
Snortとは、OSS(オープンソース)のネットワーク型IDS(侵入システム:Intrusion Detection System)として有名なソフトウェアです。商用版とGPL(GUN Public License)で配布されているフリー版があり、今回はフリー版を使用します。多くのLinuxディストリビューションをはじめ、WindowsやUnixなど様々なOSで使用できます。不正アクセスなどを検知するために、「シグネチャ」(言いにくい)と呼ばれるルールを設定します。シグネチャは、独自のものを作成する(local.rules)ことが可能です。シグネチャは、ルールヘッダとルールバディという2つの部分からできております。

環境:
OS CentOS Linux release 8.3.2011
アーキテクチャ x86_64
kernelバージョン 4.18.0-240.10.1.el8_3.x86_64

作業:
下記のサイトから最新のSnortを調べてください。
https://www.snort.org/downloads/
今回は、「snort-2.9.18-1.centos8.x86_64.rpm」を使用します。

# yum install https://www.snort.org/downloads/snort/snort-2.9.18-1.centos8.x86_64.rpm

下記のエラーが発生したらepel導入後、「daq」をインストールしてください。
Snortエラー.PNG

・epelの導入

# yum install epel-release

下記のコマンドは、デフォルトにしないためのコマンドなので必須ではないです。
※sedコマンドでenabled=1→enabled=0に置換しております。

# sed -i 's/enabled=1/enabled=0/g' /etc/yum.repos.d/epel.repo

・daqのインストール

# yum --enablerepo=epel install daq

再度「snort-2.9.18-1.centos8.x86_64.rpm」をインストールして完了です!!!!!
Snort完了.PNG

起動:
snortdサービス起動させます。

# systemctl start snortd

結果です。
snortd起動結果.PNG
libdnet.1が無いらしいです。
libdnetをインストールします。

# yum install libdnet

シンボリックリンク作成します。

# ln -s /usr/lib64/libdnet.so.1.0.1 /usr/lib64/libdnet.1

参考サイト:
https://acind.hatenablog.jp/entry/2020/06/16/110106
https://ex1.m-yabe.com/archives/4906
https://www.alprovs.com/wordpress/?p=655

駄文:
インストールは成功しますが、シグネチャを入れたりしてこの後も学習が必要ですね。一応、これで起動はできますが、まだまだ設定が必要となります。更新はするつもりですので、ご指摘やご感想などをいただければ幸いです。ヤル気が出るので。ではでは。

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?