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

context.log_level = 100 still shows corefile parsing errors #1666

Closed
Reelix opened this issue Aug 25, 2020 · 0 comments · Fixed by #2222
Closed

context.log_level = 100 still shows corefile parsing errors #1666

Reelix opened this issue Aug 25, 2020 · 0 comments · Fixed by #2222

Comments

@Reelix
Copy link

Reelix commented Aug 25, 2020

Pwntools Version: 4.2.1

If context.log_level = 100; is set, one would expect all output to be hidden.

When core = io.corefile; is run and the corefile fails to parse, a message is still output, even though you set the output level to 100

[!] Error parsing corefile stack: Found bad environment at 0x7ffcef1fffb7

From the debug log

2020-08-24T20:16:07:DEBUG:pwnlib.elf.corefile:Trying corefile_path: '/home/reelix/thm/anonymousplayground/core'
2020-08-24T20:16:07:INFO:pwnlib.elf.corefile:Parsing corefile...
2020-08-24T20:16:07:WARNING:pwnlib.elf.corefile:Error parsing corefile stack: Found bad environment at 0x7fff2f902fb7
2020-08-24T20:16:07:INFO:pwnlib.elf.corefile:'/tmp/tmp19mma2o3'
Arch:      amd64-64-little
RIP:       0x40070f
RSP:       0x7fff2f901a88
Exe:       '/home/reelix/thm/anonymousplayground/file.elf' (0x400000)
Fault:     0x6161617461616173
2020-08-24T20:16:07:INFO:pwnlib.elf.corefile:Parsing corefile...: Done
2020-08-24T20:16:07:INFO:pwnlib.elf.corefile:Parsing corefile...
2020-08-24T20:16:07:INFO:pwnlib.elf.corefile:'/home/reelix/thm/anonymousplayground/core.634721'
Arch:      amd64-64-little
RIP:       0x40070f
RSP:       0x7fff2f901a88
Exe:       '/home/reelix/thm/anonymousplayground/file.elf' (0x400000)
Fault:     0x6161617461616173
2020-08-24T20:16:07:INFO:pwnlib.elf.corefile:Parsing corefile...: Done
peace-maker added a commit to peace-maker/pwntools that referenced this issue Jul 9, 2023
If we don't want to see the log, don't print it. There are no spammy
debug logs anymore.

Fixes Gallopsled#1666
Arusekk pushed a commit that referenced this issue Jul 9, 2023
* Don't change log level for Corefile._parse_stack()

If we don't want to see the log, don't print it. There are no spammy
debug logs anymore.

Fixes #1666

* Fix doctest
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant