10일차

기타 필요 프로그램
sudo apt -y install xinetd telnetd
sudo apt -y install elinks
sudo apt -y install postfix (smtp)
sudo apt -y install sendmail (smtp)
sudo apt -y install vsftpd
wget https://ko.wordpress.org/wordpress-6.6.1-ko_KR.tar.gz
sudo apt -y install nfs-common nfs-kernel-server rpcbind
sudo apt -y install samba-common smbclient cifs-utils
sudo apt -y install isc-dhcp-server
sudo apt -y install squid
sudo apt -y install isc-dhcp-server tftpd-hpa inetutils-inetd vsftpd pxelinux
sudo apt -y install xrdp ( GUI 환경일 경우 서버용은 설치 불필요 )

칼리리눅스 명령어를 정리하라
외부에서 확인 : st.kr > /var/www/html > root
내부에서 확인 : intra.st.kr > /home/st/public_html


일반계정 홈페이지 작동시키기
1> 계정추가전에
cd /etc/skel
mkdir public_html

cd public_html
mkdir includes
mkdir auth
mkdir logs
touch index.html
touch index.php

a2enmod userdir
st.kr/~st : /home/st/public_html > Forbidden
su st
chmod 711 $HOME
chmod 755 ~/public_html

Forbidden : 접근 금지 > 접근 허용

DNS > 웹의 설정이 문제가 있다
cd /etc/apache2/sites-avaliable/hosting.conf

DocumentRoot /home/st/public_html
ServerName st.kr
ServerAdmin st@st.kr
ErrorLog /home/st/public_html/logs/error.log
CustomLog /home/st/public_html/logs/access.log combined

a2ensite hosting
systemctl restart apache2


[ESW1]
config t
monitor session 1 source interface fastethernet 1/0 - 14
monitor session 1 destination interface fastethernet 1/15
end
show monitor session 1

IDS 설치
sudo apt update
sudo apt upgrade nano /etc/hostname > IDS로 변경
sudo apt -y install net-tools
sudo apt -y install lrzsz

sudo apt -y install snort > 설치파일 없음
소스설치

설치완료후 GNS3 속으로

컨텐츠 필터링 정책
drop ip $EXTERNAL_NET any <> [192.168.0.0/24] any (content:"naver"; msg:"네이버 차단"; sid:40310003; classtype:ContentsFilter; priority:2;)
content:"naver";
content:"abc|0d0a|def";
content:"|616263|";
content:""a|0d0a|b|0d0a|;
" |22|
; |3b|
: |3a|
| |7c|

content:"http|3A|//";
content:!"패턴규칙";
content:"http1.0"; content:!"200 OK";