Tweak DH params support to add load from file.

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@35603 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
rfm 2012-09-24 10:40:37 +00:00
parent 8d6ac2f8ec
commit e7aa62096c
2 changed files with 122 additions and 21 deletions

View file

@ -67,13 +67,30 @@
+ (int) verify: (gnutls_session_t)session;
@end
/* This class provides the current DH paraqmeters for server negotiation.
/* This class provides the current autogenerated Diffie Hellman parameters
* for server negotiation and/or parameters laoded from file.
*/
@interface GSTLSDHParams : GSTLSObject
{
NSDate *when;
NSString *path;
gnutls_dh_params_t params;
}
/* Returns the most recently generated key ... if there is none this calls
* +generate to create one. Once a key has been generated, replacements
* are periodically generated in a separate thread.
*/
+ (GSTLSDHParams*) current;
/* Generate key ... really slow.
*/
+ (void) generate;
/* Return params loaded from a file.
*/
+ (GSTLSDHParams*) paramsFromFile: (NSString*)f;
- (gnutls_dh_params_t) params;
@end