projects
/
mech_eap.orig
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
use JSON instead of DDF marshalling
[mech_eap.orig]
/
util_attr.h
diff --git
a/util_attr.h
b/util_attr.h
index
347842a
..
1a427f7
100644
(file)
--- a/
util_attr.h
+++ b/
util_attr.h
@@
-41,9
+41,7
@@
#include <string>
#include <new>
#include <string>
#include <new>
-#include <shibsp/remoting/ddf.h>
-
-using namespace shibsp;
+#include <jansson.h>
struct gss_eap_attr_provider;
struct gss_eap_attr_ctx;
struct gss_eap_attr_provider;
struct gss_eap_attr_ctx;
@@
-131,25
+129,28
@@
public:
{
}
{
}
+ /* prefix to be prepended to attributes emitted by gss_get_name_attribute */
virtual const char *prefix(void) const
{
return NULL;
}
virtual const char *prefix(void) const
{
return NULL;
}
- virtual const char *marshallingKey(void) const
+ /* optional key for storing JSON dictionary */
+ virtual const char *name(void) const
{
return NULL;
}
{
return NULL;
}
- virtual bool
unmarshallAndIni
t(const gss_eap_attr_ctx *manager,
-
DDF &
object GSSEAP_UNUSED)
+ virtual bool
initWithJsonObjec
t(const gss_eap_attr_ctx *manager,
+
json_t *
object GSSEAP_UNUSED)
{
return initWithManager(manager);
}
{
return initWithManager(manager);
}
- virtual DDF marshall(void) const
+
+ virtual json_t *jsonRepresentation(void) const
{
{
- return
DDF(NULL)
;
+ return
NULL
;
}
virtual time_t getExpiryTime(void) const { return 0; }
}
virtual time_t getExpiryTime(void) const { return 0; }
@@
-253,8
+254,8
@@
private:
unsigned int attributePrefixToType(const gss_buffer_t prefix) const;
gss_buffer_desc attributeTypeToPrefix(unsigned int type) const;
unsigned int attributePrefixToType(const gss_buffer_t prefix) const;
gss_buffer_desc attributeTypeToPrefix(unsigned int type) const;
- bool
unmarshallAndInit(DDF &
object);
-
DDF marshall
(void) const;
+ bool
initWithJsonObject(json_t *
object);
+
json_t *jsonRepresentation
(void) const;
gss_eap_attr_provider *getPrimaryProvider(void) const;
gss_eap_attr_provider *getPrimaryProvider(void) const;