MCPcopy Create free account
hub / github.com/SecurityAnalysts01/ShellcodeLoader / safe_module_enumerator

Class safe_module_enumerator

Loading/Loading/lazy_importer.hpp:430–455  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

428 };
429
430 struct safe_module_enumerator {
431 using value_type = const detail::win::LDR_DATA_TABLE_ENTRY_T;
432 value_type* value;
433 value_type* head;
434
435 LAZY_IMPORTER_FORCEINLINE safe_module_enumerator() noexcept
436 : safe_module_enumerator(ldr_data_entry())
437 {}
438
439 LAZY_IMPORTER_FORCEINLINE
440 safe_module_enumerator(const detail::win::LDR_DATA_TABLE_ENTRY_T* ldr) noexcept
441 : value(ldr->load_order_next()), head(value)
442 {}
443
444 LAZY_IMPORTER_FORCEINLINE void reset() noexcept
445 {
446 value = head->load_order_next();
447 }
448
449 LAZY_IMPORTER_FORCEINLINE bool next() noexcept
450 {
451 value = value->load_order_next();
452
453 return value != head && value->DllBase;
454 }
455 };
456
457 struct unsafe_module_enumerator {
458 using value_type = const detail::win::LDR_DATA_TABLE_ENTRY_T*;

Callers 1

Calls 1

load_order_nextMethod · 0.45

Tested by

no test coverage detected