一.系统:CentOS 6.5 64位 二.方法:读取/var/log/secure,查找关键字 Failed,例如(注:文中的IP地址特意做了删减): Sep 17 09:08:09 localhost sshd[29087]: Failed password for root from 13.7.3.6 port 44367 ssh2Sep 17 09:08:20 localhost sshd[29087]: Failed password for root from 13.7.3.6 po
一.ssh密钥对无交互登录 实战1:通过密钥进行sshd服务认证 服务端:linl_S IP:10.0.0.15 客户端:lin_C IP:10.0.0.16 1)在客户端生成密钥对 命令:ssh-keygen 1 [[email protected]_C ~]# ssh-keygen 2 Generating public/private rsa key pair. 3 Enter file in which to save the key (/root/.ssh/id_rsa):
自己用树莓派搭建了个小server,用了很长时间了,最近查看log发现有很多SSH登陆失败,瞬间心就碎了,一直没关心小派的安全问题,怪我咯! 马上行动,首先研究下log:/var/log/auth.log记录了SSH登陆等权限安全信息,如何知道自己被攻击了呢? # grep sshd.\*Failed /var/log/auth.log | less Nov 16 11:26:44 raspberrypi2 sshd[4876]: Failed password for root from 61