Skip to content

Accept args given in the format string of printf-like functions - #1038

Closed
generalmimon wants to merge 4 commits into
pwndbg:devfrom
generalmimon:accept-printf-args
Closed

generalmimon wants to merge 4 commits into
pwndbg:devfrom
generalmimon:accept-printf-args

Conversation

@generalmimon

Copy link
Copy Markdown

Cc @disconnect3d (made on the EuroPython 2022 sprint)

See #939

It doesn't really adjust the value format (as I thought it would when I provide the argument type, but it turns out it's not interpreted anywhere), so e.g. for floats you won't get anything nice as 1.5 but still some unreadable 0x..., but at least it's a start of reading printf arguments.

@codecov-commenter

codecov-commenter commented Jul 16, 2022 •

Copy link
Copy Markdown

Codecov Report

Merging #1038 (89bd51a) into dev (8cc0ab8) will decrease coverage by 0.13%.
The diff coverage is 1.85%.

@@            Coverage Diff             @@
##              dev    #1038      +/-   ##
==========================================
- Coverage   49.82%   49.68%   -0.14%     
==========================================
  Files         159      159              
  Lines       18627    18681      +54     
  Branches     1512     1530      +18     
==========================================
+ Hits         9280     9281       +1     
- Misses       9047     9100      +53     
  Partials      300      300              
Impacted Files Coverage Δ
pwndbg/arguments.py 20.98% <1.85%> (-9.57%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8cc0ab8...89bd51a. Read the comment docs.

See pwndbg#939

It doesn't really adjust the value format (as I thought it would when I
provide the argument type, but it turns out it's not interpreted
anywhere), so e.g. for floats you won't get anything nice as 1.5 but
still some unreadable 0x..., but at least it's a start of reading
`printf` arguments.
As the code comment explains, the table is not currently used, but it
may be useful in the future.
Comment thread pwndbg/arguments.py
@disconnect3d

Copy link
Copy Markdown
Member

I'll close this for now but keep a reference to it in #939

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants