C Language How to store the permission bytes of a file (highlighted) in a string and then print it out alongside the for
Posted: Sat Nov 27, 2021 2:15 pm
C Language
How to store the permission bytes of a file (highlighted) in a
string and then print it out alongside the format number
(8)
Output should be something like this:
.25 00000000: 6338 2d72 7720 722d 2d72 2d2d 0700 3235 C8-rw-r--r- 00000010: 362e 6269 600 0100 0000 0000 0102 0304 6.bin... 00000020: 0506 0708 090a Oboc Odbe of10 1112 1314 00000030: 1516 1718 191a 1b1c idle 1f20 2122 2324 !"#$ 00000040: 2526 2728 292a 2b2c 2d2e 2f30 3132 3334 %&'()*+,-./01234 00000050: 3536 3738 393a 3b3c 3d3e 3f40 4142 4344 56789:;<=>?@ABCD 00000060: 4546 4748 494a 4b4c4d4e 4f50 5152 5354 EFGHIJKLMNOPQRST 00000070: 5556 5758 595a 5b5c 5d5e 5f60 6162 6364 UVWXYZ[\]^_`abcd 00000080: 6566 6768 696a 6b6c 6d6e 6f70 7172 7374 efghijklmnopqrst 00000090: 7576 7778 797a 7b7c 7d7e 7f80 8182 8384 uvwxyz{|}-... 00000000: 8586 8788 898a 8b8c 8d8e 8f90 9192 9394 000000b0: 9596 9798 999a 9b9c 9d9e 9fa0 ala2 a3a4 00000000: a5a6 a7a8 a9aa abac adae afbo b1b2 b3b4 00000000: b5b6 b7b8 beba bbbc bdbe bfco clc2 c304 0000000: c5 c6 c7c8 c9ca cbcc cdce cfdo d1d2 d3d4 000000f0: d5d6 d7d8 d9da dbdc ddde dfeo ele2 e3e4
-rw-r--r-- 00 8
How to store the permission bytes of a file (highlighted) in a
string and then print it out alongside the format number
(8)
Output should be something like this:
.25 00000000: 6338 2d72 7720 722d 2d72 2d2d 0700 3235 C8-rw-r--r- 00000010: 362e 6269 600 0100 0000 0000 0102 0304 6.bin... 00000020: 0506 0708 090a Oboc Odbe of10 1112 1314 00000030: 1516 1718 191a 1b1c idle 1f20 2122 2324 !"#$ 00000040: 2526 2728 292a 2b2c 2d2e 2f30 3132 3334 %&'()*+,-./01234 00000050: 3536 3738 393a 3b3c 3d3e 3f40 4142 4344 56789:;<=>?@ABCD 00000060: 4546 4748 494a 4b4c4d4e 4f50 5152 5354 EFGHIJKLMNOPQRST 00000070: 5556 5758 595a 5b5c 5d5e 5f60 6162 6364 UVWXYZ[\]^_`abcd 00000080: 6566 6768 696a 6b6c 6d6e 6f70 7172 7374 efghijklmnopqrst 00000090: 7576 7778 797a 7b7c 7d7e 7f80 8182 8384 uvwxyz{|}-... 00000000: 8586 8788 898a 8b8c 8d8e 8f90 9192 9394 000000b0: 9596 9798 999a 9b9c 9d9e 9fa0 ala2 a3a4 00000000: a5a6 a7a8 a9aa abac adae afbo b1b2 b3b4 00000000: b5b6 b7b8 beba bbbc bdbe bfco clc2 c304 0000000: c5 c6 c7c8 c9ca cbcc cdce cfdo d1d2 d3d4 000000f0: d5d6 d7d8 d9da dbdc ddde dfeo ele2 e3e4
-rw-r--r-- 00 8