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

Fix iS hash outputs #16044

Merged
merged 1 commit into from Feb 24, 2020
Merged

Fix iS hash outputs #16044

merged 1 commit into from Feb 24, 2020

Conversation

abcSup
Copy link
Contributor

@abcSup abcSup commented Feb 24, 2020

  • Refactor bin_sections function
  • Add filter_hash_string function

Your checklist for this pull request

  • I've read the guidelines for contributing to this repository
  • I made sure to follow the project's coding style
  • I've added tests that prove my fix is effective or that my feature works (if possible)
  • I've updated the documentation and the radare2 book with the relevant information (if needed)

Detailed description

Previously, iS entropy does not include entropy outputs as reported by @apasamar on Telegram. This PR is to include every hash option (entropy,sha1,...) in iS table outputs.

[0x080483d0]> iS entropy
[Sections]

nth paddr        size vaddr       vsize perm entropy    name
――――――――――――――――――――――――――――――――――――――――――――――――――――――――――――
0   0x00000000    0x0 0x00000000    0x0 ---- 0.00000000 
1   0x00000154   0x13 0x08048154   0x13 -r-- 3.68188080 .interp
2   0x00000168   0x20 0x08048168   0x20 -r-- 1.74868984 .note.ABI_tag
3   0x00000188   0x38 0x08048188   0x38 -r-- 1.23442903 .hash
4   0x000001c0   0x20 0x080481c0   0x20 -r-- 1.99254169 .gnu.hash
5   0x000001e0   0x90 0x080481e0   0x90 -r-- 1.56755604 .dynsym
6   0x00000270   0x5f 0x08048270   0x5f -r-- 4.38707564 .dynstr
7   0x000002d0   0x12 0x080482d0   0x12 -r-- 1.19417373 .gnu.version
8   0x000002e4   0x20 0x080482e4   0x20 -r-- 1.66055053 .gnu.version_r
9   0x00000304    0x8 0x08048304    0x8 -r-- 2.75000000 .rel.dyn
10  0x0000030c   0x30 0x0804830c   0x30 -r-- 2.94082791 .rel.plt
11  0x0000033c   0x17 0x0804833c   0x17 -r-x 3.46241535 .init
12  0x00000354   0x70 0x08048354   0x70 -r-x 3.51876869 .plt
13  0x000003d0  0x274 0x080483d0  0x274 -r-x 5.76534324 .text
14  0x00000644   0x1a 0x08048644   0x1a -r-x 3.79621760 .fini
15  0x00000660   0x55 0x08048660   0x55 -r-- 4.59175306 .rodata
16  0x000006b8    0x4 0x080486b8    0x4 -r-- 0.00000000 .eh_frame
17  0x00000f0c    0x8 0x08049f0c    0x8 -rw- 1.00000000 .ctors
18  0x00000f14    0x8 0x08049f14    0x8 -rw- 1.00000000 .dtors
19  0x00000f1c    0x4 0x08049f1c    0x4 -rw- 0.00000000 .jcr
20  0x00000f20   0xd0 0x08049f20   0xd0 -rw- 2.82161069 .dynamic
21  0x00000ff0    0x4 0x08049ff0    0x4 -rw- 0.00000000 .got
22  0x00000ff4   0x24 0x08049ff4   0x24 -rw- 2.98068211 .got.plt
23  0x00001018    0xc 0x0804a018    0xc -rw- 1.58496250 .data
24  0x00001024    0x0 0x0804a024    0x4 -rw- 0.00000000 .bss
25  0x00001024  0x1b9 0x00000000  0x1b9 ---- 4.50015849 .comment
26  0x000011dd   0xdb 0x00000000   0xdb ---- 4.21638420 .shstrtab
27  0x00001740  0x460 0x00000000  0x460 ---- 3.06854806 .symtab
28  0x00001ba0  0x248 0x00000000  0x248 ---- 4.85613827 .strtab

* Refactor bin_sections function
* Add filter_hash_string function
@github-actions github-actions bot added the command New commands requests, behaviour changes, removal label Feb 24, 2020
@radare radare merged commit 97498c3 into radareorg:master Feb 24, 2020
@radare
Copy link
Collaborator

radare commented Feb 24, 2020

awesome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
command New commands requests, behaviour changes, removal
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants