Thu Apr 28 2011 17:13:54

Asterisk developer's documentation


cryptostub.c File Reference

Stubs for res_crypto routines. More...

#include "asterisk.h"
#include "asterisk/crypto.h"
#include "asterisk/logger.h"
Include dependency graph for cryptostub.c:

Go to the source code of this file.

Defines

#define build_stub(func_name,...)

Functions

 build_stub (ast_check_signature, struct ast_key *key, const char *msg, const char *sig)
 build_stub (ast_decrypt_bin, unsigned char *dst, const unsigned char *src, int srclen, struct ast_key *key)
 build_stub (ast_encrypt_bin, unsigned char *dst, const unsigned char *src, int srclen, struct ast_key *key)
 build_stub (ast_sign_bin, struct ast_key *key, const char *msg, int msglen, unsigned char *sig)
 build_stub (ast_sign, struct ast_key *key, char *msg, char *sig)
 build_stub (ast_check_signature_bin, struct ast_key *key, const char *msg, int msglen, const unsigned char *sig)
static struct ast_keystub_ast_key_get (const char *kname, int ktype)

Variables

struct ast_key *(* ast_key_get )(const char *key, int type)
 Retrieve a key.

Detailed Description

Stubs for res_crypto routines.

Author:
Mark Spencer <markster@digium.com>

Definition in file cryptostub.c.


Define Documentation

#define build_stub (   func_name,
  ... 
)

Definition at line 50 of file cryptostub.c.


Function Documentation

build_stub ( ast_check_signature  ,
struct ast_key key,
const char *  msg,
const char *  sig 
)
build_stub ( ast_decrypt_bin  ,
unsigned char *  dst,
const unsigned char *  src,
int  srclen,
struct ast_key key 
)
build_stub ( ast_encrypt_bin  ,
unsigned char *  dst,
const unsigned char *  src,
int  srclen,
struct ast_key key 
)
build_stub ( ast_sign_bin  ,
struct ast_key key,
const char *  msg,
int  msglen,
unsigned char *  sig 
)
build_stub ( ast_sign  ,
struct ast_key key,
char *  msg,
char *  sig 
)
build_stub ( ast_check_signature_bin  ,
struct ast_key key,
const char *  msg,
int  msglen,
const unsigned char *  sig 
)
static struct ast_key* stub_ast_key_get ( const char *  kname,
int  ktype 
) [static, read]

Definition at line 33 of file cryptostub.c.

References ast_log(), and LOG_NOTICE.

{
   ast_log(LOG_NOTICE, "Crypto support not loaded!\n");
   return NULL;
}

Variable Documentation

struct ast_key*(* ast_key_get)(const char *key, int type)
Initial value:

Retrieve a key.

Parameters:
nameof the key we are retrieving
inttype of key (AST_KEY_PUBLIC or AST_KEY_PRIVATE)
Return values:
thekey on success.
NULLon failure.

Definition at line 60 of file cryptostub.c.

Referenced by authenticate(), authenticate_verify(), check_key(), crypto_init(), register_verify(), and update_key().