Add support for adding/removing/modifying contacts and groups.
[siplcs.git] / src / sipkrb5.h
blob567055fbd5f036e5470ecd5626bd116809063e8c
1 /*
2 * @file sipkrb5.h
4 * Methods for using Kerberos authentication and signing with SIPE,
5 * implemented with reference to
6 * - MS-SIP: http://msdn.microsoft.com/en-us/library/cc431510.aspx
8 * Authentication is known to be working, but the signing does not work at
9 * all yet.
11 * pidgin-sipe
13 * Copyright (C) 2008 Novell, Inc.
14 * Copyright (C) 2008 Andrew Rechenberg
16 * This program is free software; you can redistribute it and/or modify
17 * it under the terms of the GNU General Public License as published by
18 * the Free Software Foundation; either version 2 of the License, or
19 * (at your option) any later version.
21 * This program is distributed in the hope that it will be useful,
22 * but WITHOUT ANY WARRANTY; without even the implied warranty of
23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 * GNU General Public License for more details.
26 * You should have received a copy of the GNU General Public License
27 * along with this program; if not, write to the Free Software
28 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
31 #ifndef _PIDGIN_SIPE_KRB5_H
32 #define _PIDGIN_SIPE_KRB5_H
34 #include <glib.h>
35 #include <time.h>
37 #include "cipher.h"
38 #include "circbuffer.h"
39 #include "dnsquery.h"
40 #include "dnssrv.h"
41 #include "network.h"
42 #include "proxy.h"
43 #include "prpl.h"
44 #include "sslconn.h"
46 #include "sipmsg.h"
47 #include <gssapi.h>
49 struct sipe_krb5_auth {
50 const char * authuser;
51 const char * realm;
52 char * password;
53 const char * hostname;
54 const char * service;
56 char * token;
57 gchar * base64_token;
59 gss_ctx_id_t * gss_context;
62 void purple_krb5_init_auth(struct sipe_krb5_auth *, const char *authuser, const char *realm, char *password, const char *hostname, const char *service);
63 void purple_krb5_gen_auth_token(struct sipe_krb5_auth * auth);
65 gchar * purple_krb5_get_mic(struct sipe_krb5_auth * auth, char * msg);
66 gchar * purple_krb5_get_mic_for_sipmsg(struct sipe_krb5_auth * auth, struct sipmsg * msg);
68 #endif /* _PIDGIN_SIPE_KRB5_H */