Noise-C
 All Data Structures Files Functions Variables Typedefs Macros Groups Pages
Functions
loader.c File Reference

Key loading and saving implementation. More...

#include <noise/keys.h>
#include <noise/protocol.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>

Go to the source code of this file.

Functions

int noise_load_certificate_chain_from_buffer (Noise_CertificateChain **chain, NoiseProtobuf *pbuf)
 Loads a certificate chain from a protobuf. More...
 
int noise_load_certificate_chain_from_file (Noise_CertificateChain **chain, const char *filename)
 Loads a certificate chain from a file. More...
 
int noise_load_certificate_from_buffer (Noise_Certificate **cert, NoiseProtobuf *pbuf)
 Loads a certificate from a protobuf. More...
 
int noise_load_certificate_from_file (Noise_Certificate **cert, const char *filename)
 Loads a certificate from a file. More...
 
int noise_load_private_key_from_buffer (Noise_PrivateKey **key, NoiseProtobuf *pbuf, const void *passphrase, size_t passphrase_len)
 Loads a private key from a protobuf. More...
 
int noise_load_private_key_from_file (Noise_PrivateKey **key, const char *filename, const void *passphrase, size_t passphrase_len)
 Loads a private key from a file. More...
 
int noise_save_certificate_chain_to_buffer (const Noise_CertificateChain *chain, NoiseProtobuf *pbuf)
 Saves a certificate chain to a protobuf. More...
 
int noise_save_certificate_chain_to_file (const Noise_CertificateChain *chain, const char *filename)
 Saves a certificate chain to a file. More...
 
int noise_save_certificate_to_buffer (const Noise_Certificate *cert, NoiseProtobuf *pbuf)
 Saves a certificate to a protobuf. More...
 
int noise_save_certificate_to_file (const Noise_Certificate *cert, const char *filename)
 Saves a certificate to a file. More...
 
int noise_save_private_key_to_buffer (const Noise_PrivateKey *key, NoiseProtobuf *pbuf, const void *passphrase, size_t passphrase_len, const char *protect_name)
 Saves a private key in encrypted form to a protobuf. More...
 
int noise_save_private_key_to_file (const Noise_PrivateKey *key, const char *filename, const void *passphrase, size_t passphrase_len, const char *protect_name)
 Saves a private key in encrypted form to a file. More...
 

Detailed Description

Key loading and saving implementation.

Definition in file loader.c.