「Snort」の版間の差分

提供: セキュリティ
移動: 案内検索
 
(同じ利用者による、間の3版が非表示)
行8: 行8:
 
[[Snort]] は、ネットワーク型のIDS (NIDS) です。
 
[[Snort]] は、ネットワーク型のIDS (NIDS) です。
 
[[Snort]] は、GPL ライセンスです。
 
[[Snort]] は、GPL ライセンスです。
 
 
== サポートするOS ==
 
== サポートするOS ==
 
* [[Linux]]
 
* [[Linux]]
 
* [[Windows]]
 
* [[Windows]]
* *BSD ([[FreeBSD]], [[NetBSD]], [[OpenBSD]])
+
* *BSD ([[FreeBSD]], NetBSD, OpenBSD)
* [[Unix]] ( [[Solaris]], [[SunOS]] , etc )
+
* [[Unix]] ( Solaris, SunOS , etc )
 
+
 
== インストール ==
 
== インストール ==
 
* [[SnortをFreeBSDにインストールする]]
 
* [[SnortをFreeBSDにインストールする]]
 
 
== 設定 ==
 
== 設定 ==
 
* [[Snortの設定 FreeBSD]]
 
* [[Snortの設定 FreeBSD]]
 
+
* [[Snortの設定関係のエラー]]
<syntaxhighlight lang="bash">
+
sudo vim /usr/local/etc/snort/snort.conf
+
</syntaxhighlight>
+
 
+
<syntaxhighlight lang="bash">
+
# Setup the network addresses you are protecting
+
ipvar HOME_NET [YOU_NEED_TO_SET_HOME_NET_IN_snort.conf]
+
</syntaxhighlight>
+
 
+
<syntaxhighlight lang="bash">
+
ipvar HOME_NET 192.168.0.0/16
+
</syntaxhighlight>
+
 
+
include をすべてコメントアウトします。
+
 
+
<syntaxhighlight lang="bash">
+
sudo touch /usr/local/etc/snort/./rules/local.rules
+
sudo mkdir /usr/local/etc/rules/
+
sudo touch /usr/local/etc/rules/{white_list,black_list}.rules
+
</syntaxhighlight>
+
 
+
<syntaxhighlight lang="bash">
+
sudo sysrc snort_interface=em0
+
</syntaxhighlight>
+
 
+
 
== 使い方 ==
 
== 使い方 ==
 
+
* [[Snortのシグネチャの作成方法]]
=== Snort が起動しない場合 ===
+
自分の使用しているネットワークの[[IPアドレス]]を設定する必要があります。
+
<syntaxhighlight lang="bash">
+
% sudo /usr/local/etc/rc.d/snort onestart
+
Starting snort.
+
/usr/local/etc/rc.d/snort: WARNING: failed to start snort
+
% sudo /usr/local/bin/snort -c /usr/local/etc/snort/snort.conf
+
Running in IDS mode
+
 
+
        --== Initializing Snort ==--
+
Initializing Output Plugins!
+
Initializing Preprocessors!
+
Initializing Plug-ins!
+
Parsing Rules file "/usr/local/etc/snort/snort.conf"
+
ERROR: /usr/local/etc/snort/snort.conf(45) Failed to parse the IP address: [YOU_NEED_TO_SET_HOME_NET_IN_snort.conf].
+
Fatal Error, Quitting..
+
</syntaxhighlight>
+
 
+
 
+
=== ルールがないと動かない ===
+
 
+
ERROR: /usr/local/etc/snort/./rules/local.rules(0) Unable to open rules file
+
<syntaxhighlight lang="bash">
+
sudo touch "/usr/local/etc/snort/./rules/local.rules"
+
</syntaxhighlight>
+
 
+
<syntaxhighlight lang="bash">
+
% sudo local/etc/rbin/snort -c /usr/local/etc/snort/snort.conf
+
Running in IDS mode
+
 
+
        --== Initializing Snort ==--
+
Initializing Output Plugins!
+
Initializing Preprocessors!
+
Initializing Plug-ins!
+
Parsing Rules file "/usr/local/etc/snort/snort.conf"
+
PortVar 'HTTP_PORTS' defined :  [ 80:90 311 383 591 593 631 901 1220 1414 1741
+
1830 2301 2381 2809 3037 3057 3128 3443 3702 4343 4848 5250 6080 6988 7000:7001
+
7144:7145 7510 7777 7779 8000 8008 8014 8028 8080 8085 8088 8090 8118 8123
+
8180:8181 8222 8243 8280 8300 8500 8800 8888 8899 9000 9060 9080 9090:9091 9443
+
9999:10000 11371 34443:34444 41080 50000 50002 55555 ]
+
PortVar 'SHELLCODE_PORTS' defined :  [ 0:79 81:65535 ]
+
PortVar 'ORACLE_PORTS' defined :  [ 1024:65535 ]
+
PortVar 'SSH_PORTS' defined :  [ 22 ]
+
PortVar 'FTP_PORTS' defined :  [ 21 2100 3535 ]
+
PortVar 'SIP_PORTS' defined :  [ 5060:5061 5600 ]
+
PortVar 'FILE_DATA_PORTS' defined :  [ 80:90 110 143 311 383 591 593 631 901
+
1220 1414 1741 1830 2301 2381 2809 3037 3057 3128 3443 3702 4343 4848 5250 6080
+
6988 7000:7001 7144:7145 7510 7777 7779 8000 8008 8014 8028 8080 8085 8088 8090
+
8118 8123 8180:8181 8222 8243 8280 8300 8500 8800 8888 8899 9000 9060 9080
+
9090:9091 9443 9999:10000 11371 34443:34444 41080 50000 50002 55555 ]
+
PortVar 'GTP_PORTS' defined :  [ 2123 2152 3386 ]
+
Detection:
+
  Search-Method = AC-Full-Q
+
    Split Any/Any group = enabled
+
    Search-Method-Optimizations = enabled
+
    Maximum pattern length = 20
+
ERROR: /usr/local/etc/snort/./rules/local.rules(0) Unable to open rules file
+
"/usr/local/etc/snort/./rules/local.rules": No such file or directory.
+
 
+
Fatal Error, Quitting..
+
</syntaxhighlight>
+
 
+
=== usbus0 でエラーになる ===
+
 
+
インターフェースを指定してない場合、自動的にインターフェースが選択されて、動作しませんでした。
+
[[FreeBSD]] の場合は、 rc.conf にsnort_interfaceでインターフェースを指定できます。
+
<syntaxhighlight lang="bash">
+
[ Port Based Pattern Matching Memory ]
+
[ Number of patterns truncated to 20 bytes: 0 ]
+
pcap DAQ configured to passive.
+
Acquiring network traffic from "usbus0".
+
Reload thread starting...
+
Reload thread started, thread 0x28805500 (49289)
+
ERROR: Cannot decode data link type 186
+
Fatal Error, Quitting..
+
</syntaxhighlight>
+
 
+
snort コマンド には、-i でインターフェースが指定できます。
+
<syntaxhighlight lang="bash">
+
sudo /usr/local/bin/snort -c /usr/local/etc/snort/snort.conf -i em0
+
</syntaxhighlight>
+
 
+
 
== 関連項目 ==
 
== 関連項目 ==
 
{{snort}}
 
{{snort}}
<!--
+
<!-- vim: filetype=mediawiki
vim: filetype=mediawiki
+
 
-->
 
-->

2015年9月23日 (水) 16:32時点における最新版

ソースファイア が開発する Snort とは、オープンソース のネットワーク侵入検知システム(IDS, Intrusion Detection System) とネットワーク侵入防止システム (IPS, Intrusion Prevention System) です。

読み方

Snort
すのーと

概要

Snort は、ネットワーク型のIDS (NIDS) です。 Snort は、GPL ライセンスです。

サポートするOS

インストール

設定

使い方

関連項目