Added the random crypto module with its default implementation, implemented the Ed25519 keys generation function

This commit is contained in:
Gu://em_ 2026-07-04 11:08:11 +02:00
parent 1216dc2282
commit ff60995aaa
3 changed files with 44 additions and 26 deletions

15
src/crypto/random.zig Normal file
View file

@ -0,0 +1,15 @@
pub const Implementation = struct {
generate: *const fn (out: []u8) void,
};
// TODO
pub const defaultImplementation = struct {
pub fn generate(out: []u8) void {
// WARNING This is not secure at all, use only for testing purposes
for(out) |*byte| {
byte *= undefined;
}
}
};