xboxkrnl SHA crypt stubs

This commit is contained in:
Dr. Chat 2015-06-02 22:51:14 -05:00
parent 40a6a12800
commit b448d794c5
5 changed files with 53 additions and 0 deletions

View File

@ -176,6 +176,7 @@
<ClCompile Include="src\xenia\kernel\xam_voice.cc" />
<ClCompile Include="src\xenia\kernel\xboxkrnl_audio.cc" />
<ClCompile Include="src\xenia\kernel\xboxkrnl_audio_xma.cc" />
<ClCompile Include="src\xenia\kernel\xboxkrnl_crypt.cc" />
<ClCompile Include="src\xenia\kernel\xboxkrnl_debug.cc" />
<ClCompile Include="src\xenia\kernel\xboxkrnl_hal.cc" />
<ClCompile Include="src\xenia\kernel\xboxkrnl_io.cc" />

View File

@ -718,6 +718,9 @@
<ClCompile Include="src\xenia\kernel\xam_nui.cc">
<Filter>src\xenia\kernel</Filter>
</ClCompile>
<ClCompile Include="src\xenia\kernel\xboxkrnl_crypt.cc">
<Filter>src\xenia\kernel</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="src\xenia\emulator.h">

View File

@ -0,0 +1,46 @@
/**
******************************************************************************
* Xenia : Xbox 360 Emulator Research Project *
******************************************************************************
* Copyright 2015 Ben Vanik. All rights reserved. *
* Released under the BSD license - see LICENSE in the root for more details. *
******************************************************************************
*/
#include "xenia/base/logging.h"
#include "xenia/kernel/kernel_state.h"
#include "xenia/kernel/util/shim_utils.h"
#include "xenia/kernel/xboxkrnl_private.h"
#include "xenia/xbox.h"
namespace xe {
namespace kernel {
typedef struct {
xe::be<DWORD> count;
xe::be<DWORD> state[5];
xe::be<BYTE> buffer[64];
} XECRYPT_SHA_STATE;
void XeCryptShaInit(pointer_t<XECRYPT_SHA_STATE> sha_state) {
sha_state.Zero();
}
DECLARE_XBOXKRNL_EXPORT(XeCryptShaInit, ExportTag::kStub);
void XeCryptShaUpdate(pointer_t<XECRYPT_SHA_STATE> sha_state,
lpvoid_t input, dword_t input_size) {
}
DECLARE_XBOXKRNL_EXPORT(XeCryptShaUpdate, ExportTag::kStub);
void XeCryptShaFinal(pointer_t<XECRYPT_SHA_STATE> sha_state, lpvoid_t out,
dword_t out_size) {
}
DECLARE_XBOXKRNL_EXPORT(XeCryptShaFinal, ExportTag::kStub);
void xe::kernel::xboxkrnl::RegisterCryptExports(
xe::cpu::ExportResolver* export_resolver, KernelState* kernel_state) {}
} // namespace kernel
} // namespace xe

View File

@ -30,6 +30,7 @@ XboxkrnlModule::XboxkrnlModule(Emulator* emulator, KernelState* kernel_state)
// Register all exported functions.
xboxkrnl::RegisterAudioExports(export_resolver_, kernel_state_);
xboxkrnl::RegisterAudioXmaExports(export_resolver_, kernel_state_);
xboxkrnl::RegisterCryptExports(export_resolver_, kernel_state_);
xboxkrnl::RegisterDebugExports(export_resolver_, kernel_state_);
xboxkrnl::RegisterErrorExports(export_resolver_, kernel_state_);
xboxkrnl::RegisterHalExports(export_resolver_, kernel_state_);

View File

@ -25,6 +25,8 @@ void RegisterAudioExports(xe::cpu::ExportResolver* export_resolver,
KernelState* kernel_state);
void RegisterAudioXmaExports(xe::cpu::ExportResolver* export_resolver,
KernelState* kernel_state);
void RegisterCryptExports(xe::cpu::ExportResolver* export_resolver,
KernelState* kernel_state);
void RegisterDebugExports(xe::cpu::ExportResolver* export_resolver,
KernelState* kernel_state);
void RegisterErrorExports(xe::cpu::ExportResolver* export_resolver,