Thanks, but I noticed that the hash changes when a filé is saved even even it is not chanced. How can I get md5 check sum from it?
Hey,
On 05/15/17 15:48, Leonel Gaspar Soares wrote:
> Hello, I would like to print the hash string of my files in dtnoutbox,
> but when I make this line in the code:
>
> cout << of.getHash().getHash()<<endl;
>
> to get all the hashes, the caracters that I see are not readable. Can
> anybody help me to convert these characters to readable form?
that's easy. IBR-DTN uses OpenSSL's MD5 interface for that ([0] and
corresponding). Thus, MD5 hashes are stored plain in 16 Bytes. Just
convert the contents of the string to hex and you get the familiar
representation.
[0]
https://github.com/ibrdtn/ibrdtn/blob/1da5501fc3fc29c52ddfe694671d5c1147a94046/ibrdtn/tools/src/io/ObservedFile.cpp#L160
Best, Martin
--
,---- [ contact info ]
| Martin Wegner, M.Sc.
| IBR, research group Connected and Mobile Systems
| Technische Universität Braunschweig
| office:
| Mühlenpfordtstraße 23, room 131
| 38106 Braunschweig, Germany
| phone: +49 531 391 3246
| mail: wegner@ibr.cs.tu-bs.de
| GnuPG key: 0x04210FF947C76DD7
`----
--
!! This message is brought to you via the `ibr-dtn' mailing list.
!! Please do not reply to this message to unsubscribe. To unsubscribe or adjust
!! your settings, send a mail message to <ibr-dtn-request@ibr.cs.tu-bs.de>
!! or look at https://mail.ibr.cs.tu-bs.de/listinfo/ibr-dtn.