Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

167
Views
.text section address range of position independent executable

I want the address of the .text section of a position independent executable. Using readelf -S:

Name              Type             Address           Offset
       Size              EntSize          Flags  Link  Info  Align
.text             PROGBITS         0000000000002700  00002700
       0000000000001672  0000000000000000  AX       0     0     16

I learn that it will begin 0x2700 bytes past where library was loaded into memory. But how can I get the load address of the executable? Is there any other way to get the .text section address range during runtime (from the running program)?

over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

Is there any other way to get the .text section address range during runtime (from the running program)?

Yes: you need to use dl_iterate_phdr and use info->dlpi_addr to locate the PIE binary in memory at runtime. The very first call to your callback will be for the main executable.

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!