sofia-sip/auth_ntlm.h

Go to the documentation of this file.
00001 /*
00002  * This file is part of the Sofia-SIP package
00003  *
00004  * Copyright (C) 2005 Nokia Corporation.
00005  *
00006  * Contact: Pekka Pessi <pekka.pessi@nokia-email.address.hidden>
00007  *
00008  * This library is free software; you can redistribute it and/or
00009  * modify it under the terms of the GNU Lesser General Public License
00010  * as published by the Free Software Foundation; either version 2.1 of
00011  * the License, or (at your option) any later version.
00012  *
00013  * This library is distributed in the hope that it will be useful, but
00014  * WITHOUT ANY WARRANTY; without even the implied warranty of
00015  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
00016  * Lesser General Public License for more details.
00017  *
00018  * You should have received a copy of the GNU Lesser General Public
00019  * License along with this library; if not, write to the Free Software
00020  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
00021  * 02110-1301 USA
00022  *
00023  */
00024 
00025 #ifndef AUTH_NTLM_H
00026 
00027 #define AUTH_NTLM_H 
00028 
00048 #ifndef SU_ALLOC_H
00049 #include <sofia-sip/su_alloc.h>
00050 #endif
00051 
00052 #ifndef AUTH_PLUGIN_H
00053 #include <sofia-sip/auth_plugin.h>
00054 #endif
00055 
00056 SOFIA_BEGIN_DECLS
00057 
00058 
00059 int auth_ntlm_challenge_get(su_home_t *, auth_challenge_t *, 
00060                               char const * const params[]);
00061 int auth_ntlm_response_get(su_home_t *, auth_response_t *, 
00062                              char const * const params[]);
00063 
00064 int auth_ntlm_a1(auth_response_t *ar, 
00065                    auth_hexmd5_t ha1,
00066                    char const *secret);
00067 
00068 int auth_ntlm_a1sess(auth_response_t *ar, 
00069                        auth_hexmd5_t ha1sess,
00070                        char const *ha1);
00071 
00072 int auth_ntlm_sessionkey(auth_response_t *, auth_hexmd5_t ha1,
00073                            char const *secret);
00074 int auth_ntlm_response(auth_response_t *, auth_hexmd5_t response,
00075                          auth_hexmd5_t const ha1, 
00076                          char const *method_name, void const *data, int dlen);
00077 
00079 msg_auth_t *auth_ntlm_credentials(msg_auth_t *auth, 
00080                                   char const *realm,
00081                                   char const *opaque,
00082                                   char const *gssapidata,
00083                                   char const *targetname);
00084 
00085 void auth_challenge_ntlm(auth_mod_t *am, 
00086                          auth_status_t *as,
00087                          auth_challenger_t const *ach);
00088 
00089 
00090 void auth_method_ntlm(auth_mod_t *am,
00091                       auth_status_t *as,
00092                       msg_auth_t *au,
00093                       auth_challenger_t const *ach);
00094 
00095 
00096 void auth_check_ntlm(auth_mod_t *am,
00097                      auth_status_t *as,
00098                      auth_response_t *ar,
00099                      auth_challenger_t const *ach);
00100 
00101 int auth_generate_ntlm_nonce(auth_mod_t *am, 
00102                              char buffer[],
00103                              size_t buffer_len,
00104                              int nextnonce,
00105                              msg_time_t now);
00106 
00107 int auth_validate_ntlm_nonce(auth_mod_t *am, 
00108                              auth_status_t *as,
00109                              auth_response_t *ar,
00110                              msg_time_t now);
00111 
00112 void auth_info_ntlm(auth_mod_t *am, 
00113                     auth_status_t *as,
00114                     auth_challenger_t const *ach);
00115 
00116 SOFIA_END_DECLS
00117 
00118 #endif

Sofia-SIP 1.12.1 - Copyright (C) 2006 Nokia Corporation. All rights reserved. Licensed under the terms of the GNU Lesser General Public License.