谁有类似变速齿轮的源代码? 原理不一样吗?都是Hook API 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 这是兄弟的代码,谁知道怎么用吗?比如加速、原速和慢速,谢谢!void Ring0(){ //在Windows9x下进入ring0后进行的操作 __asm { cli mov al,34h out 43h,al //写入8253控制寄存器,设置写0号定时器 mov ax,bx out 40h,al //写定时值低位 mov al,ah out 40h,al //写定时值高位 sti iretd; }}void SetClockNT(int freq){ //NT下的操作 //这里使用了NT Port库 Outport(0x43,0x34); //写入8253控制寄存器,设置写0号定时器 Outport(0x40,freq&0xff); //写定时值低位 Outport(0x40,(freq>>8)&0xff); //写定时值高位}void SetClock9x(int freq){ union Function_Pointer { void (*pointer)(); char bytes[sizeof(void *)]; }OldIntAddress,NewIntAddress; int IDTAddress; //IDT表基地址 int IDTItemAddress; //要修改的中断门所在地址 char *Pointer; //要修改的中断门所在地址,指针形式 __asm { push eax sidt [esp-2] pop eax mov IDTAddress,eax //得到IDT表基地址 } IDTItemAddress=FREE_INT_NO*8+IDTAddress; Pointer=(char *)IDTItemAddress; NewIntAddress.pointer=Ring0; OldIntAddress.bytes[0]=Pointer[0]; OldIntAddress.bytes[1]=Pointer[1]; OldIntAddress.bytes[2]=Pointer[6]; OldIntAddress.bytes[3]=Pointer[7]; //保存旧的中断门 Pointer[0]=NewIntAddress.bytes[0]; Pointer[1]=NewIntAddress.bytes[1]; Pointer[6]=NewIntAddress.bytes[2]; Pointer[7]=NewIntAddress.bytes[3]; //设置新的中断门 __asm { mov ebx,freq int FREE_INT_NO //产生中断,进入ring0 } Pointer[0]=OldIntAddress.bytes[0]; Pointer[1]=OldIntAddress.bytes[1]; Pointer[6]=OldIntAddress.bytes[2]; Pointer[7]=OldIntAddress.bytes[3]; //恢复旧的中断门} 在win9x中是通过进入ring0级 然后对8253控制寄存器进行读写。其中在win9x中是通过中断门进入ring0级的,当然进入ring0级还可以用其他的方法,只不过利用中断门比较方便.关于中断门,调用门的概念 可以看看 保护模式 有关的书籍 :) 比如这个函数void SetClock9x(int freq)我试了一下freq=500速度飞快,5马上死机不知道怎么恢复原来速度,谢谢! 开发包是VB的,有VC的全部源代码就好了!!! 要啊,发我一个谢谢![email protected] >>zshuc(小巧的PE)Thank you: [email protected] 顺手也发给我个吧,谢谢[email protected] 我要[email protected]谢了! 错了:[email protected] 谢谢,也请发我一个[email protected] 我看还是公布把!!!!!!!!!!!!me too!!!:) 菜鸟求助,关于非模态对话框的串行化 对话框内贴一张背景图,再在图上动态产生好几个按钮? 创建Button的问题 有没有什么办法让动态库工程输出静态库 如何得到MP3文件的信息,声道数,品质等? 有没有人对去郑州做网络游戏感兴趣? 有没有熟悉遗传算法的,过来看看,很简单的问题 ATL中可以绘控件 程序在后台运行,或最小化在任务栏,怎样设置延时使之跳到前台??? 请问各位:学Java有钱途,还是学c#有钱途 请问高程考试的时候需要带身份证吗?(立即给分) 我在IE中设置proxy为127.0.0.1:8999但是拨号上网后好象不经过proxy,为什么?
比如加速、原速和慢速,谢谢!void Ring0()
{ //在Windows9x下进入ring0后进行的操作
__asm
{
cli
mov al,34h
out 43h,al //写入8253控制寄存器,设置写0号定时器
mov ax,bx
out 40h,al //写定时值低位
mov al,ah
out 40h,al //写定时值高位
sti
iretd;
}
}void SetClockNT(int freq)
{ //NT下的操作
//这里使用了NT Port库
Outport(0x43,0x34); //写入8253控制寄存器,设置写0号定时器
Outport(0x40,freq&0xff); //写定时值低位
Outport(0x40,(freq>>8)&0xff); //写定时值高位
}void SetClock9x(int freq)
{
union Function_Pointer
{
void (*pointer)();
char bytes[sizeof(void *)];
}OldIntAddress,NewIntAddress; int IDTAddress; //IDT表基地址
int IDTItemAddress; //要修改的中断门所在地址
char *Pointer; //要修改的中断门所在地址,指针形式 __asm
{
push eax
sidt [esp-2]
pop eax
mov IDTAddress,eax //得到IDT表基地址
}
IDTItemAddress=FREE_INT_NO*8+IDTAddress;
Pointer=(char *)IDTItemAddress;
NewIntAddress.pointer=Ring0;
OldIntAddress.bytes[0]=Pointer[0];
OldIntAddress.bytes[1]=Pointer[1];
OldIntAddress.bytes[2]=Pointer[6];
OldIntAddress.bytes[3]=Pointer[7]; //保存旧的中断门 Pointer[0]=NewIntAddress.bytes[0];
Pointer[1]=NewIntAddress.bytes[1];
Pointer[6]=NewIntAddress.bytes[2];
Pointer[7]=NewIntAddress.bytes[3]; //设置新的中断门
__asm
{
mov ebx,freq
int FREE_INT_NO //产生中断,进入ring0
} Pointer[0]=OldIntAddress.bytes[0];
Pointer[1]=OldIntAddress.bytes[1];
Pointer[6]=OldIntAddress.bytes[2];
Pointer[7]=OldIntAddress.bytes[3]; //恢复旧的中断门
}
其中在win9x中是通过中断门进入ring0级的,当然进入ring0级还可以用其他的方法,只不过利用中断门比较方便.关于中断门,调用门的概念 可以看看 保护模式 有关的书籍 :)
我试了一下freq=500速度飞快,5马上死机
不知道怎么恢复原来速度,谢谢!
[email protected]
Thank you: [email protected]
[email protected]
谢了!
[email protected]
[email protected]
me too!!!
:)