본문 바로가기

정보공유

ipban - 원격 데스크톱에 적용 가능한 fail2ban

2. 적당한 폴더에 압축 해제

ex) C:\IPBan

 

3. CMD 관리자 권한으로 실행 후 아래 명령어 입력 : 로컬 보안정책 > 로컬정책 > 감사 정책 값을 변경합니다.

 

auditpol.exe /set /category:"{69979849-797A-11D9-BED3-505054503030}" /success:enable /failure:enable auditpol.exe /set /category:"{69979850-797A-11D9-BED3-505054503030}" /success:enable /failure:enable
 

 

 

4. 서비스로 등록하기 ( 예제입니다. 경로를 사용자 환경에 맞게 수정하세요)

 

sc.exe create IPBAN type= own start= delayed-auto binPath= C:\IPBan\DigitalRuby.IPBan.exe DisplayName= IPBAN
 
sc.exe description IPBAN "Automatically builds firewall rules for abusive login attempts:https://github.com/DigitalRuby/IPBan"
 
sc.exe failure IPBAN reset= 9999 actions= "restart/60000/restart/60000/restart/60000" sc.exe start IPBAN

 

 

5. 환경설정 파일 ipban.config 수정

 

로그인 몇회 실패하며 차단 등록?
<add key="FailedLoginAttemptsBeforeBan" value="5"/>
 
ipban 시간 ? (아래는 1)
<add key="BanTime" value="01:00:00:00"/>
 
차단후 제거 일자 (아래는 1)
<add key="ExpireTime" value="01:00:00:00"/>

재부팅~