Instelling breekpunt in dynamische loader op iOS-simulator

stemmen
0

Ik ben actief in een probleem waarbij de dynamische loader crasht in dyld_sim`memcmp. Ik probeer om te bepalen welke bibliotheek werd het laden op het moment, maar de stapel lijkt corrupt (althans, het argument registers zijn niet beschikbaar).

Dus ik ben op zoek naar een breekpunt in de lader (verderop in de stack) in te stellen, maar breekpunten in de dynamische loader niet lijken te stick. Ik heb ook geprobeerd het instellen van symbolische breakpoints, maar die niet te activeren. Ik weet niet of het is omdat ik ben spelling het verkeerd (bijvoorbeeld de locatie van dyld :: load niet werkte).

Alle ideeën voor wat ik kan proberen?

dyld_sim`memcmp:
    0x107154afd <+0>:  pushq  %rbp
    0x107154afe <+1>:  movq   %rsp, %rbp
    0x107154b01 <+4>:  testq  %rdx, %rdx
    0x107154b04 <+7>:  je     0x107154b1e               ; <+33>
    0x107154b06 <+9>:  xorl   %ecx, %ecx
->  0x107154b08 <+11>: movzbl (%rdi,%rcx), %eax         ; Thread 1: EXC_BAD_ACCESS (code=50, address=0x1090fa000)
    0x107154b0c <+15>: movzbl (%rsi,%rcx), %r8d
    0x107154b11 <+20>: cmpb   %r8b, %al
    0x107154b14 <+23>: jne    0x107154b22               ; <+37>
    0x107154b16 <+25>: incq   %rcx
    0x107154b19 <+28>: cmpq   %rcx, %rdx
    0x107154b1c <+31>: jne    0x107154b08               ; <+11>
    0x107154b1e <+33>: xorl   %eax, %eax
    0x107154b20 <+35>: jmp    0x107154b25               ; <+40>
    0x107154b22 <+37>: subl   %r8d, %eax
    0x107154b25 <+40>: popq   %rbp
    0x107154b26 <+41>: retq   
#0  0x0000000107154b08 in memcmp ()
#1  0x0000000107144051 in ImageLoaderMachO::validateFirstPages(linkedit_data_command const*, int, unsigned char const*, unsigned long, long long, ImageLoader::LinkContext const&) ()
#2  0x0000000107147266 in ImageLoaderMachOCompressed::instantiateFromFile(char const*, int, unsigned char const*, unsigned long, unsigned long long, unsigned long long, stat const&, unsigned int, unsigned int, linkedit_data_command const*, encryption_info_command const*, ImageLoader::LinkContext const&) ()
#3  0x000000010714316f in ImageLoaderMachO::instantiateFromFile(char const*, int, unsigned char const*, unsigned long, unsigned long long, unsigned long long, stat const&, ImageLoader::LinkContext const&) ()
#4  0x00000001071356e1 in dyld::loadPhase6(int, stat const&, char const*, dyld::LoadContext const&) ()
#5  0x0000000107139ffd in dyld::loadPhase5(char const*, char const*, dyld::LoadContext const&, unsigned int&, std::__1::vector<char const*, std::__1::allocator<char const*> >*) ()
#6  0x0000000107139bbd in dyld::loadPhase4(char const*, char const*, dyld::LoadContext const&, unsigned int&, std::__1::vector<char const*, std::__1::allocator<char const*> >*) ()
#7  0x000000010713926a in dyld::loadPhase2(char const*, char const*, dyld::LoadContext const&, char const* const*, char const* const*, unsigned int&, std::__1::vector<char const*, std::__1::allocator<char const*> >*) ()
#8  0x000000010713912a in dyld::loadPhase1(char const*, char const*, dyld::LoadContext const&, unsigned int&, std::__1::vector<char const*, std::__1::allocator<char const*> >*) ()
#9  0x000000010713541c in dyld::loadPhase0(char const*, char const*, dyld::LoadContext const&, unsigned int&, std::__1::vector<char const*, std::__1::allocator<char const*> >*) ()
#10 0x00000001071350e6 in dyld::load(char const*, dyld::LoadContext const&, unsigned int&) ()
#11 0x000000010713a4ef in dyld::libraryLocator(char const*, bool, char const*, ImageLoader::RPathChain const*, bool, unsigned int&) ()
#12 0x0000000107140a2e in ImageLoader::recursiveLoadLibraries(ImageLoader::LinkContext const&, bool, ImageLoader::RPathChain const&, char const*) ()
#13 0x000000010713fc8a in ImageLoader::link(ImageLoader::LinkContext const&, bool, bool, bool, ImageLoader::RPathChain const&, char const*) ()
#14 0x0000000107136cc8 in dyld::link(ImageLoader*, bool, bool, ImageLoader::RPathChain const&, unsigned int) ()
#15 0x0000000107138123 in dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) ()
#16 0x0000000107133630 in start_sim ()
#17 0x00000001107168cc in dyld::useSimulatorDyld(int, macho_header const*, char const*, int, char const**, char const**, char const**, unsigned long*, unsigned long*) ()
#18 0x0000000110714575 in dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) ()
#19 0x000000011070f227 in dyldbootstrap::start(dyld3::MachOLoaded const*, int, char const**, dyld3::MachOLoaded const*, unsigned long*) ()
#20 0x000000011070f025 in _dyld_start ()
De vraag is gesteld op 19/03/2020 om 21:57
bron van user
In andere talen...                            

Cookies help us deliver our services. By using our services, you agree to our use of cookies. Learn more