Testcase specification document

Testname: Application stacks non-executable

Document Owner:

Jogi Sievers

Last document change:

25.10.2006

Status of document:

Standard

Valid for version: StarOffice8 PP4

Test purpose:

Application stacks should be marked non-executable


Known issues:


Preconditions of test:

Solaris operating system with


Test documents:

-


Testcases:

dump method

Status: Standard

-

  1. Start OpenOffice.org / StarOffice
  2. Open a terminal or console window on the Solaris operating system
  3. Type in the terminal window:
    /usr/ccs/bin/dump -ov <path_to_installed_office>/program/soffice.bin
  4. You will see something like this:
     ***** PROGRAM EXECUTION HEADER *****
    Type Offset Vaddr Paddr
    Filesz Memsz Flags Align

    PHDR 0x34 0x10034 0
    0xc0 0xc0 r-x 0

    INTERP 0xf4 0 0
    0x11 0 r-- 0

    LOAD 0 0x10000 0
    0x5d72a 0x5d72a r-x 0x10000

    LOAD 0x5d72c 0x7d72c 0
    0x3de8 0x3e2c rwx 0x10000

    DYN 0x5f6bc 0x7f6bc 0
    0x218 0 rwx 0

    SUNWSTACK 0 0 0
    0 0 rw- 0
  5. The testcase have been passed if the SUNWSTACK exists and has only rw- and no rwx rights. No execute rights.

pmap method

Status: Standard

-

  1. Start OpenOffice.org / StarOffice
  2. Open a terminal or a console window on the Solaris operating system
  3. Type in the terminal window:
    ps -ef|grep soffice.bin
  4. You will see something like this and get the id from the running process:
    <your_login_id> 43434 37912   0 13:41:48 pts/64      0:00 grep soffice.bin
  5. Type in the terminal window:
    /usr/bin/pmap -x 37912
  6. And you will see something like this:
    Address  Kbytes     RSS    Anon  Locked Mode   Mapped File
    00010000 376 368 - - r-x-- soffice.bin
    0007C000 24 24 16 - rwx-- soffice.bin
    00082000 6248 6224 5816 - rwx-- [ heap ]
    ...
    FF280000 848 848 - - r-x-- libc.so.1
    FF364000 32 32 24 - rwx-- libc.so.1
    FF36C000 8 8 8 - rwx-- libc.so.1
    FF380000 8 8 8 - rwx-- [ anon ]
    FF390000 8 8 8 - rwx-- [ anon ]
    FF3A0000 24 24 24 - rwx-- [ anon ]
    FF3B0000 176 176 - - r-x-- ld.so.1
    FF3E4000 16 16 - - r-x-- libthread.so.1
    FF3EC000 8 8 8 - rwx-- ld.so.1
    FF3EE000 8 8 8 - rwx-- ld.so.1
    FF3F8000 16 16 - - r-x-- libpthread.so.1
    FFBF6000 40 40 40 - rw--- [ stack ]
  7. The testcase is passed if the stack-entry exists and is not executable (x-flag)