1 /* GIO - GLib Pin, Output and Pkcs11ing Library
3 * Copyright © 2011 Collabora Ltd.
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU Lesser General Public License as published
7 * by the Free Software Foundation; either version 2 of the licence or (at
8 * your option) any later version.
10 * See the included COPYING file for more information.
12 * Author: Stef Walter <stefw@collabora.co.uk>
15 #ifndef __G_PKCS11_PIN_H__
16 #define __G_PKCS11_PIN_H__
19 #include <p11-kit/pin.h>
23 #define G_TYPE_PKCS11_PIN (g_pkcs11_pin_get_type ())
24 #define G_PKCS11_PIN(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), G_TYPE_PKCS11_PIN, GPkcs11Pin))
25 #define G_PKCS11_PIN_CLASS(class) (G_TYPE_CHECK_CLASS_CAST ((class), G_TYPE_PKCS11_PIN, GPkcs11PinClass))
26 #define G_IS_PKCS11_PIN(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), G_TYPE_PKCS11_PIN))
27 #define G_IS_PKCS11_PIN_CLASS(class) (G_TYPE_CHECK_CLASS_TYPE ((class), G_TYPE_PKCS11_PIN))
28 #define G_PKCS11_PIN_GET_CLASS(inst) (G_TYPE_INSTANCE_GET_CLASS ((inst), G_TYPE_PKCS11_PIN, GPkcs11PinClass))
30 typedef struct _GPkcs11PinPrivate GPkcs11PinPrivate;
31 typedef struct _GPkcs11PinClass GPkcs11PinClass;
32 typedef struct _GPkcs11Pin GPkcs11Pin;
34 struct _GPkcs11PinClass
36 GTlsPasswordClass parent_class;
41 GTlsPassword parent_instance;
42 GPkcs11PinPrivate *priv;
45 GType g_pkcs11_pin_get_type (void) G_GNUC_CONST;
47 GTlsPassword * g_pkcs11_pin_new (GTlsPasswordFlags flags,
48 const gchar *description);
50 P11KitPin * g_pkcs11_pin_steal_internal (GPkcs11Pin *self);
54 #endif /* __G_PKCS11_PIN_H___ */