Re: [wiki] Monocypher rocks!

From: luiz <bloataware_AT_tutanota.com>
Date: Mon, 12 Sep 2022 23:33:51 +0200 (CEST)

Thanks for the replies!

I assumed that this statement was kinda true because if you write something like this:
#include "monocypher.h"

void main()
{
uint8_t hash[64];
const uint8_t message[] = "hello, world";

crypto_blake2b(hash, message, 12);
}

void _start()
{
main();
}

Compile it with the '-nostdlib' flag, as stated by Tom Schwindl, and then run gdb, everything *seems* fine.
Sincerely,
luiz



Sep 12, 2022, 17:59 by schwindl_AT_posteo.de:

> On Mon Sep 12, 2022 at 10:44 PM CEST, Tom Schwindl wrote:
>
>> Hi,
>>
>> On Mon Sep 12, 2022 at 9:09 PM CEST, Lancia Greggori wrote:
>> > >It has no dependencies (NOT EVEN ON LIBC).
>> > How is it possible to write a C library with absolutely no dependency on
>> > libc?
>> >
>>
>> Simply pass `-nostdlib' and do not include any standard headers.
>>
>
> Of course you'd have to handle all the nasty details such as writing your
> own `_start' and initializing all sort of things. Not a fun thing to do.
>
>> --
>> Best Regards,
>> Tom Schwindl
>>
Received on Mon Sep 12 2022 - 23:33:51 CEST

This archive was generated by hypermail 2.3.0 : Mon Sep 12 2022 - 23:36:49 CEST