Changeset 93256 in vbox for trunk/src/VBox/HostDrivers
- Timestamp:
- Jan 17, 2022 12:14:27 AM (3 years ago)
- svn:sync-xref-src-repo-rev:
- 149318
- Location:
- trunk/src/VBox/HostDrivers/Support
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/HostDrivers/Support/Makefile.kmk
r93254 r93256 438 438 ifneq ($(VBOX_VCC_LD_GUARD_CF),) 439 439 SUPR3HardenedStatic_SOURCES.win += \ 440 $(SUPR3HardenedStatic_0_OUTDIR)/loadcfg.obj 441 # These are for the /guard option. 442 SUPR3HardenedStatic_SOURCES.win += \ 440 443 $(SUPR3HardenedStatic_0_OUTDIR)/loadcfg.obj \ 441 444 $(SUPR3HardenedStatic_0_OUTDIR)/gs_cookie.obj \ … … 443 446 $(SUPR3HardenedStatic_0_OUTDIR)/guard_dispatch.obj \ 444 447 $(SUPR3HardenedStatic_0_OUTDIR)/guard_xfg_dispatch.obj 448 # These next ones are for supporting the /GS option. We skip gs_report.obj as it 449 # import lots from kernel32 and we're better of reporting the problem ourselves. 450 SUPR3HardenedStatic_SOURCES.win += \ 451 $(SUPR3HardenedStatic_0_OUTDIR)/amdsecgs.obj \ 452 $(SUPR3HardenedStatic_0_OUTDIR)/gshandler.obj 445 453 446 454 $$(SUPR3HardenedStatic_0_OUTDIR)/loadcfg.obj \ … … 449 457 $$(SUPR3HardenedStatic_0_OUTDIR)/guard_dispatch.obj \ 450 458 $$(SUPR3HardenedStatic_0_OUTDIR)/guard_xfg_dispatch.obj \ 459 $$(SUPR3HardenedStatic_0_OUTDIR)/amdsecgs.obj \ 460 $$(SUPR3HardenedStatic_0_OUTDIR)/gs_report.obj \ 461 $$(SUPR3HardenedStatic_0_OUTDIR)/gshandler.obj \ 451 462 : \ 452 463 $(PATH_TOOL_$(VBOX_VCC_TOOL)_LIB)/libcmt.lib | $$(dir $$@) -
trunk/src/VBox/HostDrivers/Support/win/SUPR3HardenedMain-win.cpp
r93115 r93256 485 485 } 486 486 487 488 /** 489 * Called when there is some /GS (or maybe /RTCsu) related stack problem. 490 * 491 * We don't want the CRT version living in gshandle.obj, as it uses a lot of 492 * kernel32 imports, we want to report this error ourselves. 493 */ 494 extern "C" __declspec(noreturn guard(nosspro) guard(nossepi)) 495 void __cdecl __report_rangecheckfailure(void) 496 { 497 supR3HardenedFatal("__report_rangecheckfailure called from %p", ASMReturnAddress()); 498 } 499 500 501 /** 502 * Called when there is some /GS problem has been detected. 503 * 504 * We don't want the CRT version living in gshandle.obj, as it uses a lot of 505 * kernel32 imports, we want to report this error ourselves. 506 */ 507 extern "C" __declspec(noreturn guard(nosspro) guard(nossepi)) 508 #ifdef RT_ARCH_X86 509 void __cdecl __report_gsfailure(void) 510 #else 511 void __report_gsfailure(uintptr_t uCookie) 512 #endif 513 { 514 #ifdef RT_ARCH_X86 515 supR3HardenedFatal("__report_gsfailure called from %p", ASMReturnAddress()); 516 #else 517 supR3HardenedFatal("__report_gsfailure called from %p, cookie=%p", ASMReturnAddress(), uCookie); 518 #endif 519 } 487 520 488 521
Note:
See TracChangeset
for help on using the changeset viewer.