Skip to content

Commit

Permalink
changed test
Browse files Browse the repository at this point in the history
  • Loading branch information
ddkwork committed Jul 18, 2024
1 parent f4cec48 commit beb3c13
Show file tree
Hide file tree
Showing 14 changed files with 12 additions and 9 deletions.
Binary file modified sdk/bin/hyperdbg-cli.exe
Binary file not shown.
Binary file modified sdk/bin/hyperhv.dll
Binary file not shown.
Binary file modified sdk/bin/hyperkd.sys
Binary file not shown.
Binary file modified sdk/bin/hyperlog.dll
Binary file not shown.
Binary file modified sdk/bin/kdserial.dll
Binary file not shown.
Binary file modified sdk/bin/libhyperdbg.dll
Binary file not shown.
Binary file modified sdk/bin/pdbex.dll
Binary file not shown.
Binary file modified sdk/bin/script-engine.dll
Binary file not shown.
Binary file modified sdk/bin/symbol-parser.dll
Binary file not shown.
4 changes: 2 additions & 2 deletions sdk/bindgen/SDK/Imports/User/HyperDbgLibImports.h
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ hyperdbg_u_show_signature();
IMPORT_EXPORT_LIBHYPERDBG VOID
hyperdbg_u_set_text_message_callback(PVOID handler);

IMPORT_EXPORT_LIBHYPERDBG VOID
hyperdbg_u_set_text_message_callback_using_shared_buffer(PVOID handler, PVOID shared_buffer);
IMPORT_EXPORT_LIBHYPERDBG PVOID
hyperdbg_u_set_text_message_callback_using_shared_buffer(PVOID handler);

IMPORT_EXPORT_LIBHYPERDBG VOID
hyperdbg_u_unset_text_message_callback();
Expand Down
4 changes: 2 additions & 2 deletions sdk/bindgen/merged_headers.h
Original file line number Diff line number Diff line change
Expand Up @@ -4646,8 +4646,8 @@ hyperdbg_u_show_signature();
IMPORT_EXPORT_LIBHYPERDBG VOID
hyperdbg_u_set_text_message_callback(PVOID handler);

IMPORT_EXPORT_LIBHYPERDBG VOID
hyperdbg_u_set_text_message_callback_using_shared_buffer(PVOID handler, PVOID shared_buffer);
IMPORT_EXPORT_LIBHYPERDBG PVOID
hyperdbg_u_set_text_message_callback_using_shared_buffer(PVOID handler);

IMPORT_EXPORT_LIBHYPERDBG VOID
hyperdbg_u_unset_text_message_callback();
Expand Down
5 changes: 3 additions & 2 deletions sdk/sdk.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion sdk/sdk_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@ func TestSdk(t *testing.T) {
assert.True(t, SetCustomDriverPathEx(SysPath))

mylog.Call(func() {
SetTextMessageCallbackUsingSharedBuffer(unsafe.Pointer(reflect.ValueOf(LogCallback).Pointer()), unsafe.Pointer(&LogBuffer[0]))
buffer := SetTextMessageCallbackUsingSharedBuffer(unsafe.Pointer(reflect.ValueOf(LogCallback).Pointer()))
gobuffer := BytePointerToString((*byte)(buffer))
println(gobuffer)
// SetTextMessageCallback(Callback(reflect.ValueOf(LogCallback).Pointer()))
})
//go func() {
Expand Down
4 changes: 2 additions & 2 deletions sdk/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,14 @@ import (
"github.com/ddkwork/golibrary/stream/bitfield"
)

var LogBuffer = make([]byte, 1, 1024)
var LogBuffer = make([]byte, 1, 1024*8)

func LogCallbackOk() {
LogCallback(&LogBuffer[0])
}

func LogCallback(message *Char) {
println("LogCallback")
// println("LogCallback")
// mylog.Info("test", "LogCallback")
}

Expand Down

0 comments on commit beb3c13

Please sign in to comment.