X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=blobdiff_plain;f=crypt_backend.h;h=175a6881c3d6567137513043055f548700c6ab65;hp=481a215fb24bc4257c1faebde329c07fa1d7ff1e;hb=f5c010bd27e131fca0c2ae58ebdde80e44655dcc;hpb=c5e38315901ea63efd169af5d4ba3f3c66db7de9 diff --git a/crypt_backend.h b/crypt_backend.h index 481a215f..175a6881 100644 --- a/crypt_backend.h +++ b/crypt_backend.h @@ -1,16 +1,12 @@ -/* - * Copyright (C) 2011-2013 Andre Noll - * - * Licensed under the GPL v2. For licencing details see COPYING. - */ +/* Copyright (C) 2011 Andre Noll , see file COPYING. */ /** \file crypt_backend.h Non-public crypto interface. */ -/* This should only be incuded from files which provide crypto functions. */ +/* This should only be included from files which provide crypto functions. */ -size_t is_ssh_rsa_key(char *data, size_t size); -uint32_t read_ssh_u32(const void *vp); -int uudecode(const char *src, unsigned char *target, size_t targsize); -int check_ssh_key_header(const unsigned char *blob, int blen); -int check_key_file(const char *file, bool private_key); -int base64_decode(char const *src, unsigned char *target, size_t targsize); +/** AES block size in bytes. */ +#define AES_CRT128_BLOCK_SIZE 16 + +int decode_ssh_key(const char *filename, unsigned char **blob, + size_t *decoded_size); +int check_private_key_file(const char *file);