| 1 |
/* |
| 2 |
* gnome-keyring |
| 3 |
* |
| 4 |
* Copyright (C) 2010 Stefan Walter |
| 5 |
* |
| 6 |
* This program is free software; you can redistribute it and/or modify |
| 7 |
* it under the terms of the GNU Lesser General Public License as |
| 8 |
* published by the Free Software Foundation; either version 2.1 of |
| 9 |
* the License, or (at your option) any later version. |
| 10 |
* |
| 11 |
* This program is distributed in the hope that it will be useful, but |
| 12 |
* WITHOUT ANY WARRANTY; without even the implied warranty of |
| 13 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 14 |
* Lesser General Public License for more details. |
| 15 |
* |
| 16 |
* You should have received a copy of the GNU Lesser General Public |
| 17 |
* License along with this program; if not, see |
| 18 |
* <http://www.gnu.org/licenses/>. |
| 19 |
*/ |
| 20 |
|
| 21 |
#ifndef __GKM_XDG_TRUST_H__ |
| 22 |
#define __GKM_XDG_TRUST_H__ |
| 23 |
|
| 24 |
#include <glib-object.h> |
| 25 |
|
| 26 |
#include "gkm/gkm-object.h" |
| 27 |
#include "gkm/gkm-trust.h" |
| 28 |
|
| 29 |
#define GKM_XDG_FACTORY_TRUST (gkm_xdg_trust_get_factory ()) |
| 30 |
#define GKM_XDG_TYPE_TRUST (gkm_xdg_trust_get_type ()) |
| 31 |
#define GKM_XDG_TRUST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GKM_XDG_TYPE_TRUST, GkmXdgTrust)) |
| 32 |
#define GKM_XDG_TRUST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GKM_XDG_TYPE_TRUST, GkmXdgTrustClass)) |
| 33 |
#define GKM_XDG_IS_TRUST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GKM_XDG_TYPE_TRUST)) |
| 34 |
#define GKM_XDG_IS_TRUST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GKM_XDG_TYPE_TRUST)) |
| 35 |
#define GKM_XDG_TRUST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GKM_XDG_TYPE_TRUST, GkmXdgTrustClass)) |
| 36 |
|
| 37 |
typedef struct _GkmXdgTrust GkmXdgTrust; |
| 38 |
typedef struct _GkmXdgTrustClass GkmXdgTrustClass; |
| 39 |
typedef struct _GkmXdgTrustPrivate GkmXdgTrustPrivate; |
| 40 |
|
| 41 |
struct _GkmXdgTrust { |
| 42 |
GkmTrust parent; |
| 43 |
GkmXdgTrustPrivate *pv; |
| 44 |
}; |
| 45 |
|
| 46 |
struct _GkmXdgTrustClass { |
| 47 |
GkmTrustClass parent_class; |
| 48 |
}; |
| 49 |
|
| 50 |
GType gkm_xdg_trust_get_type (void); |
| 51 |
|
| 52 |
GkmXdgTrust* gkm_xdg_trust_create_for_assertion (GkmModule *module, |
| 53 |
GkmManager *manager, |
| 54 |
GkmTransaction *transaction, |
| 55 |
CK_ATTRIBUTE_PTR attrs, |
| 56 |
CK_ULONG n_attrs); |
| 57 |
|
| 58 |
void gkm_xdg_trust_replace_assertion (GkmXdgTrust *trust, |
| 59 |
GkmAssertion *assertion, |
| 60 |
GkmTransaction *transaction); |
| 61 |
|
| 62 |
void gkm_xdg_trust_remove_assertion (GkmXdgTrust *trust, |
| 63 |
GkmAssertion *assertion, |
| 64 |
GkmTransaction *transaction); |
| 65 |
|
| 66 |
gboolean gkm_xdg_trust_have_assertion (GkmXdgTrust *trust); |
| 67 |
|
| 68 |
#endif /* __GKM_XDG_TRUST_H__ */ |