Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Action needed from Sina #76

Open
SinaKarvandi opened this issue Jun 14, 2024 · 127 comments
Open

Action needed from Sina #76

SinaKarvandi opened this issue Jun 14, 2024 · 127 comments
Assignees

Comments

@SinaKarvandi
Copy link
Member

I noticed there are many issues in this repo, and I'm not sure which ones require my action. To improve our communication, I've created this Issue. Please post anything that needs my attention here, so I won't miss any of them.

我注意到这个 repo 中有很多问题,我不确定哪些需要我处理。为了改善我们的沟通,我创建了这个 Issue。请在此处发布任何需要我注意的内容,这样我就不会错过任何内容。

@ddkwork
Copy link
Contributor

ddkwork commented Jun 14, 2024

I noticed there are many issues in this repo, and I'm not sure which ones require my action. To improve our communication, I've created this Issue. Please post anything that needs my attention here, so I won't miss any of them.

我注意到这个 repo 中有很多问题,我不确定哪些需要我处理。为了改善我们的沟通,我创建了这个 Issue。请在此处发布任何需要我注意的内容,这样我就不会错过任何内容。

先来研究这个
#59

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

are you online? See #59 again please.

@SinaKarvandi
Copy link
Member Author

Hi,
Yes, I just came online. I'll check it now.

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

Hi,
Yes, I just came online. I'll check it now.

Hello you, please try build gui and handle #60 now.

@SinaKarvandi
Copy link
Member Author

I will build it now.

@SinaKarvandi
Copy link
Member Author

Could you please send me a link to which version of GCC you use? How do you install it on Windows?

@SinaKarvandi
Copy link
Member Author

I've got this error compiling it:

C:\Users\Sina\Desktop\gui>go build .
go: downloading github.com/ddkwork/app v0.0.0-20240615140632-acdad7498240
go: downloading github.com/ddkwork/golibrary v0.0.62
go: downloading github.com/richardwilkes/unison v0.70.1
go: downloading github.com/dc0d/caseconv v0.5.0
go: downloading github.com/fatih/color v1.17.0
go: downloading github.com/rivo/uniseg v0.4.7
go: downloading golang.org/x/exp v0.0.0-20240613232115-7f521ea00fb8
go: downloading golang.org/x/text v0.16.0
go: downloading golang.org/x/tools v0.22.0
go: downloading mvdan.cc/gofumpt v0.6.0
go: downloading github.com/axgle/mahonia v0.0.0-20180208002826-3358181d7394
go: downloading github.com/richardwilkes/toolbox v1.114.1
go: downloading github.com/zzl/go-win32api/v2 v2.2.0
go: downloading golang.org/x/sys v0.21.0
go: downloading github.com/alecthomas/chroma/v2 v2.14.0
go: downloading github.com/google/uuid v1.6.0
go: downloading github.com/cespare/xxhash/v2 v2.3.0
go: downloading github.com/go-gl/gl v0.0.0-20231021071112-07e5d0ea2e71
go: downloading github.com/go-gl/glfw/v3.3/glfw v0.0.0-20240506104042-037f3cc74f2a
go: downloading github.com/richardwilkes/json v0.2.0
go: downloading github.com/yuin/goldmark v1.7.2
go: downloading golang.org/x/image v0.17.0
go: downloading github.com/mattn/go-colorable v0.1.13
go: downloading github.com/mattn/go-isatty v0.0.20
go: downloading github.com/google/go-cmp v0.6.0
go: downloading golang.org/x/mod v0.18.0
go: downloading github.com/dlclark/regexp2 v1.11.0
go: downloading gopkg.in/yaml.v3 v3.0.1
go: downloading github.com/winlabs/gowin32 v0.0.0-20221003142512-0d265587d3c9
package github.com/ddkwork/hyperdbgui
        imports github.com/ddkwork/hyperdbgui/ux
        imports github.com/ddkwork/app
        imports github.com/richardwilkes/unison
        imports github.com/go-gl/gl/v3.2-core/gl: build constraints exclude all Go files in C:\Users\Sina\go\pkg\mod\github.com\go-gl\[email protected]\v3.2-core\gl
..\..\go\pkg\mod\github.com\ddkwork\[email protected]\ms\xed\pe.go:4:2: missing go.sum entry for module providing package github.com/saferwall/pe (imported by github.com/ddkwork/app/ms/xed); to add:
        go get github.com/ddkwork/app/ms/[email protected]
..\..\go\pkg\mod\github.com\ddkwork\[email protected]\ms\xed\xed.go:6:2: missing go.sum entry for module providing package golang.org/x/arch/x86/x86asm (imported by github.com/ddkwork/app/ms/xed); to add:
        go get github.com/ddkwork/app/ms/[email protected]

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

Could you please send me a link to which version of GCC you use? How do you install it on Windows?

https://github.com/jmeubank/tdm-gcc

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

wait me check agin

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

try again

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

Screenshot_20240615_225907_com.microsoft.emmx.jpg

随便一个gcc都可以的

@SinaKarvandi
Copy link
Member Author

image

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024 via email

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024 via email

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

构建成功了吗?

@SinaKarvandi
Copy link
Member Author

Another error:

C:\Users\Sina\Desktop\gui>go build .
^C
C:\Users\Sina\Desktop\gui>gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=C:/TDM-GCC-64/bin/../libexec/gcc/x86_64-w64-mingw32/10.3.0/lto-wrapper.exe
Target: x86_64-w64-mingw32
Configured with: ../../../src/gcc-git-10.3.0/configure --build=x86_64-w64-mingw32 --enable-targets=all --enable-languages=ada,c,c++,fortran,jit,lto,objc,obj-c++ --enable-libgomp --enable-lto --enable-graphite --enable-cxx-flags=-DWINPTHREAD_STATIC --disable-build-with-cxx --disable-build-poststage1-with-cxx --enable-libstdcxx-debug --enable-threads=posix --enable-version-specific-runtime-libs --enable-fully-dynamic-string --enable-libstdcxx-filesystem-ts=yes --disable-libstdcxx-pch --enable-libstdcxx-threads --enable-libstdcxx-time=yes --enable-mingw-wildcard --with-gnu-ld --disable-werror --enable-nls --disable-win32-registry --enable-large-address-aware --disable-rpath --disable-symvers --prefix=/mingw64tdm --with-local-prefix=/mingw64tdm --with-pkgversion=tdm64-1 --with-bugurl=https://github.com/jmeubank/tdm-gcc/issues
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 10.3.0 (tdm64-1)

C:\Users\Sina\Desktop\gui>go build .

C:\Users\Sina\Desktop\gui>go run .
2024-06-15 08:09:08    Trace ->  --------- title --------- │ ------------------ info ------------------ //runtime.doInit1+0xec C:/Program Files/Go/src/runtime/proc.go:7176
ERR | 2024-06-15 | 08:09:09.042 | recovered from panic
    [github.com/ddkwork/golibrary/mylog.check[...]] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/check.go:216
    [github.com/ddkwork/golibrary/mylog.Check2[...]] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/check.go:27
    [github.com/ddkwork/app/ms/xed.ParserPe] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/ms/xed/pe.go:10
    [github.com/ddkwork/hyperdbgui/ux.LayoutDisassemblyTable.func3] C:/Users/Sina/Desktop/gui/ux/cpu.go:235
    [github.com/ddkwork/app/widget.NewTable[...]] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/widget/table.go:422
    [github.com/ddkwork/hyperdbgui/ux.LayoutDisassemblyTable] C:/Users/Sina/Desktop/gui/ux/cpu.go:214
    [github.com/ddkwork/hyperdbgui/ux.LayoutCpu] C:/Users/Sina/Desktop/gui/ux/cpu.go:25
    [github.com/ddkwork/hyperdbgui/ux.NewPage] C:/Users/Sina/Desktop/gui/ux/HyperDbg.go:118
    [main.main.Run.func1] C:/Users/Sina/Desktop/gui/ux/HyperDbg.go:31
    [github.com/ddkwork/app.RunWithIco.func1.1] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/app.go:49
    [github.com/richardwilkes/toolbox.CallWithHandler] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/call.go:24
    [github.com/richardwilkes/toolbox.Call] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/call.go:18
    [github.com/richardwilkes/unison.finishStartup] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/app.go:183
    [github.com/richardwilkes/toolbox.CallWithHandler] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/call.go:24
    [github.com/richardwilkes/unison.processNextTask] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/task.go:51
    [github.com/richardwilkes/unison.processEvents] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/app.go:164
    [github.com/richardwilkes/unison.Start] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/app.go:158
    [github.com/ddkwork/app.RunWithIco.func1] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/app.go:43
    [github.com/ddkwork/golibrary/mylog.callWithHandler] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/call.go:15
    [github.com/ddkwork/golibrary/mylog.Call] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/call.go:10
    [github.com/ddkwork/app.RunWithIco] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/app.go:42
    [github.com/ddkwork/hyperdbgui/ux.Run] C:/Users/Sina/Desktop/gui/ux/HyperDbg.go:30
    [main.main] C:/Users/Sina/Desktop/gui/main.go:9
  Caused by: open D:\workspace\workspace\branch\gui\bin\debug\hyperdbg-cli.exe: The system cannot find the path specified.
    [github.com/ddkwork/golibrary/mylog.check[...]] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/check.go:216
    [github.com/ddkwork/golibrary/mylog.Check2[...]] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/check.go:27
    [github.com/ddkwork/app/ms/xed.ParserPe] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/ms/xed/pe.go:10
    [github.com/ddkwork/hyperdbgui/ux.LayoutDisassemblyTable.func3] C:/Users/Sina/Desktop/gui/ux/cpu.go:235
    [github.com/ddkwork/app/widget.NewTable[...]] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/widget/table.go:422
    [github.com/ddkwork/hyperdbgui/ux.LayoutDisassemblyTable] C:/Users/Sina/Desktop/gui/ux/cpu.go:214
    [github.com/ddkwork/hyperdbgui/ux.LayoutCpu] C:/Users/Sina/Desktop/gui/ux/cpu.go:25
    [github.com/ddkwork/hyperdbgui/ux.NewPage] C:/Users/Sina/Desktop/gui/ux/HyperDbg.go:118
    [main.main.Run.func1] C:/Users/Sina/Desktop/gui/ux/HyperDbg.go:31
    [github.com/ddkwork/app.RunWithIco.func1.1] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/app.go:49
    [github.com/richardwilkes/toolbox.CallWithHandler] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/call.go:24
    [github.com/richardwilkes/toolbox.Call] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/call.go:18
    [github.com/richardwilkes/unison.finishStartup] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/app.go:183
    [github.com/richardwilkes/toolbox.CallWithHandler] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/call.go:24
    [github.com/richardwilkes/unison.processNextTask] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/task.go:51
    [github.com/richardwilkes/unison.processEvents] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/app.go:164
    [github.com/richardwilkes/unison.Start] C:/Users/Sina/go/pkg/mod/github.com/richardwilkes/[email protected]/app.go:158
    [github.com/ddkwork/app.RunWithIco.func1] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/app.go:43
    [github.com/ddkwork/golibrary/mylog.callWithHandler] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/call.go:15
    [github.com/ddkwork/golibrary/mylog.Call] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/mylog/call.go:10
    [github.com/ddkwork/app.RunWithIco] C:/Users/Sina/go/pkg/mod/github.com/ddkwork/[email protected]/app.go:42
    [github.com/ddkwork/hyperdbgui/ux.Run] C:/Users/Sina/Desktop/gui/ux/HyperDbg.go:30
    [main.main] C:/Users/Sina/Desktop/gui/main.go:9

@SinaKarvandi
Copy link
Member Author

Did you put cli files in a static address?

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024 via email

@SinaKarvandi
Copy link
Member Author

Okay, that's fine. I'll continue the building process tomorrow. I'll go to sleep now. Good night.

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

3 min only

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

Try again

@SinaKarvandi
Copy link
Member Author

image

@SinaKarvandi
Copy link
Member Author

Great! Nice job. 👌

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

好的,您抽空action一下,这样我每次提交都会发现错误

@SinaKarvandi
Copy link
Member Author

Great. Meanwhile, I try to finish making the new SDK hopefully this week.

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024 via email

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

Screenshot_20240616_044745_com.realvnc.viewer.android.jpg

ssdt tree table layout is complete, for io, the most effective hook iopxxxcontrolfile, the rest of the ntapi as well, we will implement in each nt api right-click context menu to perform the hook operation, and at the same time pop up the hook parameter panel, enter each api's input parameter, this I have previously implemented a structure to display a smallwidget that I've implemented before, and it's perfect for doing this. Now I need to pause the layout work on ark and work on the sdk side to make debugging a high priority. I desperately want the start command to work, because the subsequent loading of the disassembly and stacking of a series of operations is possible. iopxxx that function I have previously used the disassembly engine to find the correct offsets, just need the sdk to return the nt base to me, and then adjust the appropriate content in the inputbuffer to communicate with the driver.

So the remote start command you mentioned yesterday operates under VMware? Should I loadmm first?

@ddkwork
Copy link
Contributor

ddkwork commented Jun 15, 2024

Screenshot_20240616_052242_com.realvnc.viewer.android.jpg

I don't know what the reason is, but the module is not found, and I'm thinking about implementing hyperdbgcontrol entirely in go.

https://github.com/HyperDbg/gui/blob/main/test%2Fdll%2Fdll.go#L26-L33

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024

Screenshot_20240621_190408.jpg

Screenshot_20240621_190341.jpg

@SinaKarvandi
Copy link
Member Author

okay, got it. I didn't know I should test them, probably the translator didn't give the exact meaning. I'll test them now.

好的,明白了。我不知道我应该测试它们,可能翻译没有给出确切的意思。我现在就测试它们。

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024

第三遍了

clang -fsyntax-only -nobuiltininc -Xclang -ast-dump=json combined_headers.h 
 clang -fsyntax-only -nobuiltininc -emit-llvm -Xclang -fdump-record-layouts -Xclang -fdump-record-layouts-complete combined_headers.h

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024 via email

@SinaKarvandi
Copy link
Member Author

Should I run the above command in the main GUI repo path?

我应该在主 GUI repo 路径中运行上述命令吗?

@SinaKarvandi
Copy link
Member Author

I Installed LLVM and CLANG.

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024 via email

@SinaKarvandi
Copy link
Member Author

image
image

@SinaKarvandi
Copy link
Member Author

So, what to do next? It seems it works without error for me.

那么,下一步该做什么?对我来说,它似乎没有错误。

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024 via email

@SinaKarvandi
Copy link
Member Author

image

These are the errors.

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024 via email

@SinaKarvandi
Copy link
Member Author

Not sure if I correctly understand what you mean (translation issue). Could you tell me what should I do next again?

不确定我是否正确理解了您的意思(翻译问题)。您能再告诉我下一步该怎么做吗?

@SinaKarvandi
Copy link
Member Author

Should I fix these errors? I think we need to re-order SDK headers.
我是否应该修复这些错误?我认为我们需要重新排序 SDK 标头。

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024

我已合并了pr,来测试这个

https://github.com/HyperDbg/gui/blob/main/gengo%2Fbind%2FsdkMerge%2Fmerged_headers.h

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024 via email

@SinaKarvandi
Copy link
Member Author

Okay, I'll fix it now.

@SinaKarvandi
Copy link
Member Author

Okay, let's check it one more.

I needed to change SDK (in HyperDbg) to fix these errors?
Am I right?

Do you need it right now? I think I needed to change the order in which some modules like the script-engine are used, which takes some time.

好的,我们再检查一下。

我需要更改 SDK(在 HyperDbg 中)来修复这些错误?
我说得对吗?

你现在需要吗?我想我需要更改某些模块(如脚本引擎)的使用顺序,这需要一些时间。

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024 via email

@SinaKarvandi
Copy link
Member Author

Okay, I'll fix it next week. Right now, all those functions can be ignored (removed).

好的,我下周会修复它。目前,所有这些功能都可以忽略(删除)。

@ddkwork
Copy link
Contributor

ddkwork commented Jun 21, 2024

这是我的合并实现,或许会对您修复clang错误有用
https://github.com/HyperDbg/gui/blob/main/gengo%2Fbind%2FsdkMerge%2Fbind_test.go#L35-L99

@SinaKarvandi
Copy link
Member Author

okay, I'll use it. Thanks

@SinaKarvandi
Copy link
Member Author

It needs a little bit of time since the order of headers needs to be fixed. I think I can fix it in one week.

由于需要修复标题的顺序,所以需要一点时间。我想我可以在一周内修复它。

@ddkwork ddkwork closed this as completed Jun 27, 2024
@ddkwork ddkwork reopened this Nov 15, 2024
@ddkwork
Copy link
Contributor

ddkwork commented Nov 15, 2024

Hi.你可以抽空让这个脚本工作吗?我想我需要一个实际应用中脚本工作的例子,然后按照脚本的流程让sdk api的执行顺序完全符合预期。

https://github.com/ddkwork/gui/blob/main/testdata%2Fdump_x86regFor64bit_interge_calc.ds#L1-L23

这是调试目标的源代码
https://github.com/ddkwork/asm/blob/master/main.c

编译后的文件位于脚本目录下的asm.exe 和ask.pdb

WhatsApp无法接受验证码了。

@SinaKarvandi
Copy link
Member Author

The problem with above script is that you used HyperDbg in the local debugging (VMI Mode). Instead of using these commands:

.connect local
load vmm

use the .debug command since the '.start' command only works in the Debugger Mode.

@ddkwork
Copy link
Contributor

ddkwork commented Nov 24, 2024

我将抽空让run命令在ui和go api下工作,此外,我们需要增加一种这个功能的api:

自动步入,自动步过,功能的调试api,比如说:假设f9运行程序一次,那么增加的api就是:run+运行次数

@SinaKarvandi
Copy link
Member Author

@ddkwork
Copy link
Contributor

ddkwork commented Nov 26, 2024

ok

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants