00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00029
00030 #ifndef _SML_AUTH_H_
00031 #define _SML_AUTH_H_
00032
00033 typedef struct SmlAuthenticator SmlAuthenticator;
00034 typedef SmlBool (* SmlAuthVerifyCb)(SmlChal *chal, SmlCred *cred, const char *username, void *userdata, SmlError **error);
00035
00036 SmlAuthenticator *smlAuthNew(SmlError **error);
00037 void smlAuthFree(SmlAuthenticator *auth);
00038 SmlBool smlAuthRegister(SmlAuthenticator *auth, SmlManager *manager, SmlError **error);
00039 void smlAuthSetState(SmlAuthenticator *auth, SmlErrorType type);
00040 void smlAuthSetVerifyCallback(SmlAuthenticator *auth, SmlAuthVerifyCb callback, void *userdata);
00041 void smlAuthSetEnable(SmlAuthenticator *auth, SmlBool enabled);
00042 SmlBool smlAuthIsEnabled(SmlAuthenticator *auth);
00043
00044
00045 SmlBool smlAuthVerify(SmlChal *chal, SmlCred *cred, const char *username, const char *password, SmlError **error);
00046
00047
00048 void smlAuthSetType(SmlAuthenticator *auth, SmlAuthType code);
00049
00050
00051 SmlStatus *smlAuthHeaderReply(SmlSession *session, SmlAuthType code, SmlError **error) LIBSYNCML_DEPRECATED;
00052
00053 #endif //_SML_AUTH_H_
00054