You cannot select more than 25 topics
			Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
		
		
		
		
		
			
		
			
	
	
		
			34 lines
		
	
	
		
			890 B
		
	
	
	
		
			C
		
	
		
		
			
		
	
	
			34 lines
		
	
	
		
			890 B
		
	
	
	
		
			C
		
	
| 
											11 years ago
										 | 
 | ||
|  | #ifndef __CURVE_SIGS_H__
 | ||
|  | #define __CURVE_SIGS_H__
 | ||
|  | 
 | ||
| 
											11 years ago
										 | #ifdef __cplusplus
 | ||
|  | extern "C" { | ||
|  | #endif
 | ||
|  | 
 | ||
| 
											11 years ago
										 | void curve25519_keygen(unsigned char* curve25519_pubkey_out, | ||
|  |                        unsigned char* curve25519_privkey_in); | ||
|  | 
 | ||
|  | void curve25519_sign(unsigned char* signature_out, | ||
|  |                      unsigned char* curve25519_privkey, | ||
|  |                      unsigned char* msg, unsigned long msg_len); | ||
|  | 
 | ||
|  | /* returns 0 on success */ | ||
|  | int curve25519_verify(unsigned char* signature, | ||
|  |                       unsigned char* curve25519_pubkey,                       | ||
|  |                       unsigned char* msg, unsigned long msg_len); | ||
|  | 
 | ||
|  | /* helper function - modified version of crypto_sign() to use 
 | ||
|  |    explicit private key */ | ||
|  | int crypto_sign_modified( | ||
|  |   unsigned char *sm,unsigned long long *smlen, | ||
|  |   const unsigned char *m,unsigned long long mlen, | ||
|  |   const unsigned char *sk | ||
|  |   ); | ||
|  | 
 | ||
| 
											11 years ago
										 | #ifdef __cplusplus
 | ||
|  | } | ||
|  | #endif
 | ||
|  | 
 | ||
| 
											11 years ago
										 | #endif
 |