[완료]누군가... 해킹을 시도하는 건가요?
누군가... 해킹을 시도하는 건가요?
/var/log/secure 파일을 열어봤습니다...
루트로 로그인하려고 하는것 같은데 패스워드 입력했다 틀리고 연결이 끊기고 다시 시도하는 걸로 봐서
해킹같습니다...아닌가요? 이거 어떻게 해결해야 할지요...
Aug 5 23:30:59 localhost sshd[11048]: Failed password for root from 61.135.214.
154 port 32780 ssh2
Aug 5 23:30:59 localhost sshd[11049]: Received disconnect from 61.135.214.154:
11: Bye Bye
Aug 5 23:31:00 localhost sshd[11050]: pam_unix(sshd:auth): authentication failu
re; logname= uid=0 euid=0 tty=ssh ruser= rhost=61.135.214.154 user=root
Aug 5 23:31:02 localhost sshd[11050]: Failed password for root from 61.135.214.
154 port 33249 ssh2
Aug 5 23:31:02 localhost sshd[11051]: Received disconnect from 61.135.214.154:
11: Bye Bye
Aug 5 23:31:03 localhost sshd[11052]: pam_unix(sshd:auth): authentication failu
re; logname= uid=0 euid=0 tty=ssh ruser= rhost=61.135.214.154 user=root
Aug 5 23:31:05 localhost sshd[11052]: Failed password for root from 61.135.214.
154 port 33885 ssh2
Aug 5 23:31:05 localhost sshd[11053]: Received disconnect from 61.135.214.154:
11: Bye Bye
Aug 5 23:31:06 localhost sshd[11056]: pam_unix(sshd:auth): authentication failu
re; logname= uid=0 euid=0 tty=ssh ruser= rhost=61.135.214.154 user=root
Aug 5 23:31:07 localhost sshd[11056]: Failed password for root from 61.135.214.
154 port 34477 ssh2
Aug 5 23:31:07 localhost sshd[11057]: Received disconnect from 61.135.214.154:
11: Bye Bye
Aug 5 23:31:08 localhost sshd[11059]: pam_unix(sshd:auth): authentication failu
re; logname= uid=0 euid=0 tty=ssh ruser= rhost=61.135.214.154 user=root
Aug 5 23:31:10 localhost sshd[11059]: Failed password for root from 61.135.214.
154 port 34960 ssh2
Aug 5 23:31:10 localhost sshd[11060]: Received disconnect from 61.135.214.154:
11: Bye Bye
Aug 5 23:31:11 localhost sshd[11095]: pam_unix(sshd:auth): authentication failu
re; logname= uid=0 euid=0 tty=ssh ruser= rhost=61.135.214.154 user=root
Aug 5 23:31:11 localhost login: pam_unix(login:session): session closed for use
r root
Aug 5 23:31:13 localhost sshd[11095]: Failed password for root from 61.135.214.
154 port 35615 ssh2
Aug 5 23:31:13 localhost sshd[11096]: Received disconnect from 61.135.214.154:
11: Bye Bye
Aug 5 23:31:14 localhost sshd[11214]: pam_unix(sshd:auth): authentication failu
re; logname= uid=0 euid=0 tty=ssh ruser= rhost=61.135.214.154 user=root
Aug 5 23:31:14 localhost sshd[8237]: Received signal 15; terminating.
Aug 5 23:33:07 localhost sshd[5197]: Server listening on :: port 22.
Aug 5 23:33:07 localhost sshd[5197]: error: Bind to port 22 on 0.0.0.0 failed:
Address already in use.
Aug 5 23:33:43 localhost login: pam_unix(login:session): session opened for use
r root by (uid=0)
Aug 5 23:33:43 localhost login: ROOT LOGIN ON tty1
Aug 5 23:55:06 localhost login: pam_unix(login:session): session opened for use r root by (uid=0)
Aug 5 23:55:06 localhost login: ROOT LOGIN ON tty4
Aug 6 00:26:31 localhost login: pam_unix(login:session): session closed for use r root
Aug 6 00:26:31 localhost login: pam_unix(login:session): session closed for use r root
Aug 6 00:26:35 localhost sshd[5197]: Received signal 15; terminating.
Aug 6 10:08:24 localhost sshd[8243]: Server listening on :: port 22.
Aug 6 10:08:24 localhost sshd[8243]: error: Bind to port 22 on 0.0.0.0 failed: Address already in use.
Aug 6 10:08:42 localhost login: pam_unix(login:auth): bad username [`root]
Aug 6 10:08:42 localhost login: pam_succeed_if(login:auth): error retrieving in formation about user `root
Aug 6 10:08:42 localhost login: FAILED LOGIN 1 FROM (null) FOR `root, User not known to the underlying authentication module
Aug 6 10:08:44 localhost login: pam_unix(login:session): session opened for use r root by (uid=0)
Aug 6 10:08:45 localhost login: ROOT LOGIN ON tty1
Aug 6 11:13:38 localhost runuser: pam_unix(runuser-l:session): session opened f or user cyrus by (uid=0)
Aug 6 11:13:38 localhost runuser: pam_unix(runuser-l:session): session closed f or user cyrus
[root@localhost ~]#
계속 삽질하도록
계속 삽질하도록 두세요..ㅋㅋㅋㅋㅋ
ssh 포트번호를
ssh 포트번호를 바꾸세요 ㅋㅋ
저희 회사 서버도
저희 회사 서버도 저런 로그가 산더미같이 있었는데, sshd port바꾸고 나니까 뚝 끊기더군요..
참고로 whois하니까 중국으로 나오더이다..
ssh 포트 바꾸는 법좀 알려주세효!
ssh 포트 바꾸는 법좀 알려주세효!
/etc/hosts.deny에 IP를 넣는 것도 괜찮을 듯..
계속 61.135.214.154에서 접속이 시도되니,
/etc/hosts.deny에
61.135.214.154를 넣거나,
아예 61.* 이런 형태로 넣으면 해당 IP에서 접속하기 어렵습니다.
특정 IP로 접속하는 서버라면,
/etc/hosts.deny에
*.* 넣어두고,
/etc/hosts.allow에 접속 가능한 IP를 리스팅하면 /etc/hosts.allow에
목록이 있는 IP에서만 접속이 가능합니다.
------------------------------------------------------------
If you do not expect the unexpected, you will not find it;
for it is hard to be sought out, and difficult. [Heraclitus]
------------------------------------------------------------
If you do not expect the unexpected, you will not find it;
for it is hard to be sought out, and difficult. [Heraclitus]
denyhosts
denyhosts 깔아보세요.
세번인가 다섯번인가 연속으로 패스워드 틀린 IP를 자동으로 막아줍니다.
즉, 위에 newman73 님이 말씀하신 작업을 자동으로 해줍니다.
-----
오늘 나의 취미는 끝없는, 끝없는 인내다. 1973 法頂
-----
오늘 나의 취미는 끝없는, 끝없는 인내다. 1973 法頂
Re:
61.135.214.154
Beijing, China
"Brute force attack"으로
"Brute force attack"으로 불립니다. 방어법은 이미 많이 나와있습니다. 검색으로
쉽게 찾을 수 있을 것이라 봅니다.
------------------------------------------
emacs user
------------------------------------------
emacs user
전 fail2ban을
전 fail2ban을 사용합니다.
ssh 말고도 ftp 서버 접속 패스워드가 계속 틀리면 접속을 막고 이메일로 관리자에게 알려주게끔 할 수도 있고 편하던데요.
--
academic은 제 고등학교 때 동아리 이름입니다.
academic, 아주 가끔은 저도 이랬으면 좋겠습니다.
----
academic은 제 고등학교 때 동아리 이름입니다.
academic, 아주 가끔은 저도 이랬으면 좋겠습니다.
감사합니다.
감사합니다 굉장히 흥미롭네요!
한가지씩 해보아야겠습니다^^
댓글 달기