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

Implement versioning system for DLLs #3239

Open
wants to merge 15 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions dll/ntdll/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ list(APPEND SOURCE
csr/capture.c
csr/connect.c
dbg/dbgui.c
ldr/appcompat.c
ldr/ldrapi.c
ldr/ldrinit.c
ldr/ldrpe.c
Expand Down
3 changes: 3 additions & 0 deletions dll/ntdll/include/ntdll.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,7 @@
/* PSEH */
#include <pseh/pseh2.h>

/* RosCompat */
#include <roscompat.h>

#endif /* _NTDLL_H */
20 changes: 17 additions & 3 deletions dll/ntdll/include/ntdllp.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,15 +83,20 @@ VOID NTAPI LdrpEnsureLoaderLockIsHeld(VOID);
/* ldrpe.c */
NTSTATUS
NTAPI
LdrpSnapThunk(IN PVOID ExportBase,
LdrpSnapThunk(IN PLDR_DATA_TABLE_ENTRY ExportLdrEntry,
IN PVOID ImportBase,
IN PIMAGE_THUNK_DATA OriginalThunk,
IN OUT PIMAGE_THUNK_DATA Thunk,
IN PIMAGE_EXPORT_DIRECTORY ExportEntry,
IN ULONG ExportSize,
IN BOOLEAN Static,
IN UCHAR SnapFlags,
IN LPSTR DllName);

/* SnapFlags for LdrpSnapThunk */
#define SNAP_DYNAMIC 0x0
#define SNAP_STATIC 0x1
#define SNAP_PRIVATE 0x2

NTSTATUS NTAPI
LdrpWalkImportDescriptor(IN LPWSTR DllPath OPTIONAL,
IN PLDR_DATA_TABLE_ENTRY LdrEntry);
Expand All @@ -103,7 +108,8 @@ LdrpGetProcedureAddress(IN PVOID BaseAddress,
IN PANSI_STRING Name,
IN ULONG Ordinal,
OUT PVOID *ProcedureAddress,
IN BOOLEAN ExecuteInit);
IN BOOLEAN ExecuteInit,
IN BOOLEAN UsePrivateExports);

PLDR_DATA_TABLE_ENTRY NTAPI
LdrpAllocateDataTableEntry(IN PVOID BaseAddress);
Expand Down Expand Up @@ -224,4 +230,12 @@ RtlDoesFileExists_UStr(
IN PUNICODE_STRING FileName
);

/* appcompat.c */
BOOLEAN
NTAPI
LdrpApplyRosCompatMagic(PLDR_DATA_TABLE_ENTRY LdrEntry);

extern char __ImageBase;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this used for ?



/* EOF */