2008-09-12 17:06:58 +02:00
|
|
|
/* $Id$
|
2004-12-31 12:51:11 +01:00
|
|
|
*
|
|
|
|
* Lasso - A free implementation of the Liberty Alliance specifications.
|
|
|
|
*
|
2007-05-30 19:17:45 +02:00
|
|
|
* Copyright (C) 2004-2007 Entr'ouvert
|
2004-12-31 12:51:11 +01:00
|
|
|
* http://lasso.entrouvert.org
|
2008-09-12 17:06:58 +02:00
|
|
|
*
|
2005-01-22 16:57:56 +01:00
|
|
|
* Authors: See AUTHORS file in top-level directory.
|
2004-12-31 12:51:11 +01:00
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License as published by
|
|
|
|
* the Free Software Foundation; either version 2 of the License, or
|
|
|
|
* (at your option) any later version.
|
2008-09-12 17:06:58 +02:00
|
|
|
*
|
2004-12-31 12:51:11 +01:00
|
|
|
* This program 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 General Public License for more details.
|
2008-09-12 17:06:58 +02:00
|
|
|
*
|
2004-12-31 12:51:11 +01:00
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __LASSO_PROVIDER_PRIVATE_H__
|
|
|
|
#define __LASSO_PROVIDER_PRIVATE_H__
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
2008-09-12 17:06:58 +02:00
|
|
|
#endif /* __cplusplus */
|
2004-12-31 12:51:11 +01:00
|
|
|
|
2006-11-08 18:45:45 +01:00
|
|
|
/**
|
|
|
|
* LassoPublicKeyType:
|
2009-08-26 17:15:07 +02:00
|
|
|
* @LASSO_PUBLIC_KEY_SIGNING: Signing public key
|
|
|
|
* @LASSO_PUBLIC_KEY_ENCRYPTION: Encryption public key
|
2006-11-08 18:45:45 +01:00
|
|
|
*
|
|
|
|
* Public key type.
|
2009-08-26 17:15:07 +02:00
|
|
|
*/
|
2006-11-08 18:45:45 +01:00
|
|
|
typedef enum {
|
2006-11-08 20:23:45 +01:00
|
|
|
LASSO_PUBLIC_KEY_SIGNING,
|
2009-01-24 10:33:40 +01:00
|
|
|
LASSO_PUBLIC_KEY_ENCRYPTION
|
2006-11-08 18:45:45 +01:00
|
|
|
} LassoPublicKeyType;
|
|
|
|
|
|
|
|
|
2005-11-20 16:38:19 +01:00
|
|
|
struct _LassoProviderPrivate
|
|
|
|
{
|
|
|
|
gboolean dispose_has_run;
|
2006-11-19 21:07:46 +01:00
|
|
|
|
2005-11-20 16:38:19 +01:00
|
|
|
LassoProtocolConformance conformance;
|
|
|
|
GHashTable *SPDescriptor;
|
|
|
|
char *default_assertion_consumer;
|
|
|
|
GHashTable *IDPDescriptor;
|
|
|
|
xmlNode *organization;
|
2006-11-19 21:07:46 +01:00
|
|
|
|
|
|
|
char *affiliation_owner_id;
|
2006-12-01 19:45:10 +01:00
|
|
|
char *affiliation_id;
|
2006-11-19 21:07:46 +01:00
|
|
|
|
2005-11-20 16:38:19 +01:00
|
|
|
xmlSecKey *public_key;
|
|
|
|
xmlNode *signing_key_descriptor;
|
2006-11-30 19:11:59 +01:00
|
|
|
xmlNode *encryption_key_descriptor;
|
2006-11-29 16:06:49 +01:00
|
|
|
char *encryption_public_key_str;
|
2006-11-08 18:16:31 +01:00
|
|
|
xmlSecKey *encryption_public_key;
|
2006-11-22 13:45:38 +01:00
|
|
|
LassoEncryptionMode encryption_mode;
|
2006-12-20 10:03:41 +01:00
|
|
|
LassoEncryptionSymKeyType encryption_sym_key_type;
|
2005-11-20 16:38:19 +01:00
|
|
|
};
|
|
|
|
|
2005-01-28 14:29:14 +01:00
|
|
|
|
2004-12-31 12:51:11 +01:00
|
|
|
gboolean lasso_provider_load_metadata(LassoProvider *provider, const gchar *metadata);
|
2008-11-02 12:49:55 +01:00
|
|
|
gboolean lasso_provider_load_metadata_from_buffer(LassoProvider *provider, const gchar *metadata);
|
2004-12-31 12:51:11 +01:00
|
|
|
int lasso_provider_verify_signature(LassoProvider *provider,
|
|
|
|
const char *message, const char *id_attr_name, LassoMessageFormat format);
|
2006-11-08 18:16:31 +01:00
|
|
|
gboolean lasso_provider_load_public_key(LassoProvider *provider,
|
2006-11-08 19:14:17 +01:00
|
|
|
LassoPublicKeyType public_key_type);
|
2005-09-26 17:02:52 +02:00
|
|
|
xmlSecKey* lasso_provider_get_public_key(LassoProvider *provider);
|
2009-03-27 16:04:58 +01:00
|
|
|
int lasso_provider_verify_saml_signature(LassoProvider *provider, xmlNode *signed_node, xmlDoc *doc);
|
2009-03-27 16:05:00 +01:00
|
|
|
int lasso_provider_verify_query_signature(LassoProvider *provider, const char *message);
|
2005-04-25 12:43:48 +02:00
|
|
|
|
2004-12-31 12:51:11 +01:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif /* __cplusplus */
|
|
|
|
|
|
|
|
#endif /* __LASSO_PROVIDER_PRIVATE_H__ */
|