Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tests failed #42

Open
Porlockzzz opened this issue Dec 18, 2019 · 1 comment
Open

Tests failed #42

Porlockzzz opened this issue Dec 18, 2019 · 1 comment

Comments

@Porlockzzz
Copy link

I got this error when i try to python2 setup.py test?How to fix it
`running test
testing for x86, for ARM and more args, see scripts in test/ dir
test/x86.sh build run_test clean
++ pwd

  • PROJECT_DIR=/home/porlock/rhg/exploitable-master
  • BUILD_DIR=/home/porlock/rhg/exploitable-master/build
  • echo starting
    starting
  • [[ -z build ]]
  • for cmd in $@
  • build
  • mkdir -p /home/porlock/rhg/exploitable-master/build
  • pushd /home/porlock/rhg/exploitable-master/exploitable/tests
    ~/rhg/exploitable-master/exploitable/tests ~/rhg/exploitable-master
  • make
    Makefile:31: warning: overriding recipe for target 'testStackCodeExecution.test'
    Makefile:25: warning: ignoring old recipe for target 'testStackCodeExecution.test'
    Makefile:35: warning: overriding recipe for target 'testStackBufferOverflow.test'
    Makefile:25: warning: ignoring old recipe for target 'testStackBufferOverflow.test'
    Makefile:38: warning: overriding recipe for target 'testReturnAv.test'
    Makefile:25: warning: ignoring old recipe for target 'testReturnAv.test'
    cc -fstack-protector-all -o ./bin/testStackBufferOverflow.test testStackBufferOverflow.c
    cc -o ./bin/testBlockMoveAv.test testBlockMoveAv.c
    cc -fno-stack-protector -o ./bin/testReturnAv.test testReturnAv.c
    cc -o ./bin/testSourceAv.test testSourceAv.c
    cc -o ./bin/testAbortSignal.test testAbortSignal.c
    cc -o ./bin/testDestAv.test testDestAv.c
    cc -o ./bin/testBranchAv.test testBranchAv.c
    cc -o ./bin/testFloatingPointException.test testFloatingPointException.c
    cc -o ./bin/testBenignSignal.test testBenignSignal.c
    cc -o ./bin/testHeapError.test testHeapError.c
    cc -o ./bin/testSourceAvNearNull.test testSourceAvNearNull.c
    cc -o ./bin/testSegFaultOnPc.test testSegFaultOnPc.c
    cc -o ./bin/testDestAvNearNull.test testDestAvNearNull.c
    cc -o ./bin/testBranchAvNearNull.test testBranchAvNearNull.c
    cc -o ./bin/testUncategorizedSignal.test testUncategorizedSignal.c
    cc -o ./bin/testPossibleStackCorruption.test testPossibleStackCorruption.c
    cc -o ./bin/testStackCodeExecution.test testStackCodeExecution.c
    execstack -s ./bin/testStackCodeExecution.test
    cc -o ./bin/testBadInstruction.test testBadInstruction.c
    cc -o ./bin/testSegFaultOnPcNearNull.test testSegFaultOnPcNearNull.c
    cc -o ./bin/testDeepStack.test testDeepStack.c
  • popd
    ~/rhg/exploitable-master
  • for cmd in $@
  • run_test
  • pushd /home/porlock/rhg/exploitable-master
    ~/rhg/exploitable-master ~/rhg/exploitable-master
    ++ pwd
  • export PYTHONPATH=:/home/porlock/rhg/exploitable-master/exploitable
  • PYTHONPATH=:/home/porlock/rhg/exploitable-master/exploitable
  • failed=
  • set +e
  • set +x
    verbose script debugging disabled
    testSourceAv.test: result=SourceAv expected=[u'SourceAv']
    testStackBufferOverflow.test: result=PossibleStackCorruption expected=[u'StackBufferOverflow']
    testSourceAvNearNull.test: result=SourceAvNearNull expected=[u'SourceAvNearNull']
    testBenignSignal.test: result=BenignSignal expected=[u'BenignSignal']
    testUncategorizedSignal.test: result=UncategorizedSignal expected=[u'UncategorizedSignal']
    testDeepStack.test: result=BranchAv expected=[u'PossibleStackCorruption', u'BranchAv']
    testBlockMoveAv.test: result=BlockMoveAv expected=[u'BlockMoveAv']
    testPossibleStackCorruption.test: result=PossibleStackCorruption expected=[u'PossibleStackCorruption']
    testSegFaultOnPcNearNull.test: result=SegFaultOnPcNearNull expected=[u'SegFaultOnPcNearNull']
    testAbortSignal.test: result=AbortSignal expected=[u'AbortSignal']
    testBranchAv.test: result=BranchAv expected=[u'BranchAv']
    testDestAv.test: result=DestAv expected=[u'DestAv']
    testReturnAv.test: result=SegFaultOnPc expected=[u'SegFaultOnPc']
    testDestAvNearNull.test: result=DestAvNearNull expected=[u'DestAvNearNull']
    testBadInstruction.test: result=BadInstruction expected=[u'BadInstruction']
    Traceback (most recent call last):
    File "", line 1, in
    File "/usr/lib/python2.7/pickle.py", line 1384, in load
    return Unpickler(file).load()
    File "/usr/lib/python2.7/pickle.py", line 864, in load
    dispatchkey
    File "/usr/lib/python2.7/pickle.py", line 886, in load_eof
    raise EOFError
    EOFError
    testHeapError.test:
    testStackCodeExecution.test: result=StackCodeExecution expected=[u'StackCodeExecution']
    testBranchAvNearNull.test: result=BranchAvNearNull expected=[u'BranchAvNearNull']
    testSegFaultOnPc.test: result=SegFaultOnPc expected=[u'SegFaultOnPc']
    testFloatingPointException.test: result=FloatingPointException expected=[u'FloatingPointException']
    ~/rhg/exploitable-master

TESTS FAILED:
exploitable/tests/bin/testStackBufferOverflow.test:
result=PossibleStackCorruption expected=[u'StackBufferOverflow']
cmd=gdb --batch -ex "source exploitable/exploitable.py" -ex run -ex "exploitable -v -p /home/porlock/rhg/exploitable-master/build/triage.pkl" --args exploitable/tests/bin/testStackBufferOverflow.test
exploitable/tests/bin/testHeapError.test:

            cmd=gdb --batch -ex "source exploitable/exploitable.py" -ex run -ex "exploitable -v -p /home/porlock/rhg/exploitable-master/build/triage.pkl" --args exploitable/tests/bin/testHeapError.test 

Tests failed, exiting.
done
`

@jfoote
Copy link
Owner

jfoote commented Dec 18, 2019

Hello @Porlockzzz. It looks like testHeapError.test is exiting rather than triggering an error, and testStackBufferOverflow.test is being classified as a PossibleStackCorruption, which is a weaker classification than StackBufferOverflow IIRC. Fixing this will require analysis of each of those test cases to see what has changed and making a patch here accordingly. Please feel free to dig into them if you would like. If not, I will take a look when I get a chance, but it might be a while. Thank you for reporting this issue regardless.

hal3002 pushed a commit to hal3002/exploitable that referenced this issue Aug 13, 2022
…ed that pm.name also includes the page permissions 'rw-p [stack]' instead of just ['stack']
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants