3
* Lasso - A free implementation of the Liberty Alliance specifications.
5
* Copyright (C) 2004-2007 Entr'ouvert
6
* http://lasso.entrouvert.org
8
* Authors: See AUTHORS file in top-level directory.
10
* This program is free software; you can redistribute it and/or modify
11
* it under the terms of the GNU General Public License as published by
12
* the Free Software Foundation; either version 2 of the License, or
13
* (at your option) any later version.
15
* This program is distributed in the hope that it will be useful,
16
* but WITHOUT ANY WARRANTY; without even the implied warranty of
17
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18
* GNU General Public License for more details.
20
* You should have received a copy of the GNU General Public License
21
* along with this program; if not, see <http://www.gnu.org/licenses/>.
24
#include "../private.h"
25
#include "ds_rsa_key_value.h"
28
* SECTION:ds_rsa_key_value
29
* @short_description: Object representation of an XML DSIG element to hold an RSA key
33
/*****************************************************************************/
35
/*****************************************************************************/
37
static struct XmlSnippet schema_snippets[] = {
38
{ "Modulus", SNIPPET_CONTENT, G_STRUCT_OFFSET(LassoDsRsaKeyValue, Modulus), NULL, NULL, NULL},
39
{ "Exponent", SNIPPET_CONTENT, G_STRUCT_OFFSET(LassoDsRsaKeyValue, Exponent), NULL, NULL, NULL},
40
{NULL, 0, 0, NULL, NULL, NULL}
43
/*****************************************************************************/
44
/* instance and class init functions */
45
/*****************************************************************************/
49
class_init(LassoDsRsaKeyValueClass *klass)
51
LassoNodeClass *nclass = LASSO_NODE_CLASS(klass);
53
nclass->node_data = g_new0(LassoNodeClassData, 1);
54
lasso_node_class_set_nodename(nclass, "RsaKeyValue");
55
lasso_node_class_set_ns(nclass, LASSO_DS_HREF, LASSO_DS_PREFIX);
56
lasso_node_class_add_snippets(nclass, schema_snippets);
60
lasso_ds_rsa_key_value_get_type()
62
static GType this_type = 0;
65
static const GTypeInfo this_info = {
66
sizeof (LassoDsRsaKeyValueClass),
69
(GClassInitFunc) class_init,
72
sizeof(LassoDsRsaKeyValue),
78
this_type = g_type_register_static(LASSO_TYPE_NODE,
79
"LassoDsRsaKeyValue", &this_info, 0);
85
* lasso_ds_rsa_key_value_new:
87
* Creates a new #LassoDsRsaKeyValue object.
89
* Return value: a newly created #LassoDsRsaKeyValue object
92
lasso_ds_rsa_key_value_new()
94
return g_object_new(LASSO_TYPE_DS_RSA_KEY_VALUE, NULL);