summaryrefslogtreecommitdiff
path: root/wocky/wocky-sasl-scram.h
blob: 1a355510b2920597357e998ed0d0db39c9250d6b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
#ifndef _WOCKY_SASL_SCRAM_H
/*
 * wocky-sasl-scram.h - SCRAM-SHA1 implementation (to be RFC 5802)
 * Copyright (C) 2010 Sjoerd Simons <sjoerd@luon.net>
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 */

#define _WOCKY_SASL_SCRAM_H

#include <glib-object.h>

#include "wocky-auth-handler.h"

G_BEGIN_DECLS

#define WOCKY_TYPE_SASL_SCRAM \
    wocky_sasl_scram_get_type ()

#define WOCKY_SASL_SCRAM(obj) \
    (G_TYPE_CHECK_INSTANCE_CAST ((obj), WOCKY_TYPE_SASL_SCRAM, \
        WockySaslScram))

#define WOCKY_SASL_SCRAM_CLASS(klass) \
    (G_TYPE_CHECK_CLASS_CAST ((klass), WOCKY_TYPE_SASL_SCRAM, \
        WockySaslScramClass))

#define WOCKY_IS_SASL_SCRAM(obj) \
    (G_TYPE_CHECK_INSTANCE_TYPE ((obj), WOCKY_TYPE_SASL_SCRAM))

#define WOCKY_IS_SASL_SCRAM_CLASS(klass) \
    (G_TYPE_CHECK_CLASS_TYPE ((klass), WOCKY_TYPE_SASL_SCRAM))

#define WOCKY_SASL_SCRAM_GET_CLASS(obj) \
    (G_TYPE_INSTANCE_GET_CLASS ((obj), WOCKY_TYPE_SASL_SCRAM, \
        WockySaslScramClass))

typedef struct _WockySaslScramPrivate WockySaslScramPrivate;

typedef struct
{
  GObject parent;
  WockySaslScramPrivate *priv;
} WockySaslScram;

typedef struct
{
  GObjectClass parent_class;
} WockySaslScramClass;

GType
wocky_sasl_scram_get_type (void);

WockySaslScram *
wocky_sasl_scram_new (
    const gchar *server, const gchar *username, const gchar *password);

G_END_DECLS

#endif /* _WOCKY_SASL_SCRAM_H */