According to the OrientDB's website:
OrientDB is a new Open Source NoSQL DBMS born with the best features of all the others. It's written in Java and it's amazing fast: can store up to 150,000 records per second on common hardware. Even if it's Document based database the relationships are managed as in Graph Databases with direct connections among records. You can travere entire or part of trees and graphs of records in few milliseconds. Supports schema-less, schema-full and schema-mixed modes. Has a strong security profiling system based on user and roles and support the SQL between the query languages. Thank to the SQL layer it's straightforward to use it for people skilled in Relational world.
The Gitorious repository is hosted here. You can clone it with
git clone git://gitorious.org/shibboleth-idp-orientdb-connector/shibboleth-idp-orientdb-connector.git |
mvn clean package |
Enable the connector in $IDP_CONFIG_DIR/attribute-resolver.xml
by doing the following:
xmlns:ino="http://inocybe.ca/NS/orientdb-connector" http://inocybe.ca/NS/orientdb-connector classpath:/schema/orientdb-connector.xsd |
<AttributeResolver xmlns="urn:mace:shibboleth:2.0:resolver" xmlns:resolver="urn:mace:shibboleth:2.0:resolver" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:pc="urn:mace:shibboleth:2.0:resolver:pc" xmlns:ad="urn:mace:shibboleth:2.0:resolver:ad" xmlns:dc="urn:mace:shibboleth:2.0:resolver:dc" xmlns:enc="urn:mace:shibboleth:2.0:attribute:encoder" xmlns:sec="urn:mace:shibboleth:2.0:security" xmlns:ino="http://inocybe.ca/NS/orientdb-connector" xsi:schemaLocation="urn:mace:shibboleth:2.0:resolver classpath:/schema/shibboleth-2.0-attribute-resolver.xsd urn:mace:shibboleth:2.0:resolver:pc classpath:/schema/shibboleth-2.0-attribute-resolver-pc.xsd urn:mace:shibboleth:2.0:resolver:ad classpath:/schema/shibboleth-2.0-attribute-resolver-ad.xsd urn:mace:shibboleth:2.0:resolver:dc classpath:/schema/shibboleth-2.0-attribute-resolver-dc.xsd urn:mace:shibboleth:2.0:attribute:encoder classpath:/schema/shibboleth-2.0-attribute-encoder.xsd urn:mace:shibboleth:2.0:security classpath:/schema/shibboleth-2.0-security.xsd http://inocybe.ca/NS/orientdb-connector classpath:/schema/orientdb-connector.xsd"> |
QueryTemplate
element to specify how to query the database to retrieve attributes and optional AttributeMap
elements.<resolver:DataConnector id="myOrient" xsi:type="ino:OrientDbDataConnector" orientDbHost="myorienthost.com" orientDbPort="2424" orientDbName="database" username="admin" password="password"> <ino:QueryTemplate> <![CDATA[ select from users where uid = '$requestContext.principalName' ]]> </ino:QueryTemplate> </resolver:DataConnector> |
<resolver:DataConnector id="myOrient" xsi:type="ino:OrientDbDataConnector" orientDbHost="myorienthost.com" orientDbPort="2424" orientDbName="database" username="admin" password="password"> <ino:QueryTemplate> <![CDATA[ select from users where uid = '$requestContext.principalName' ]]> </ino:QueryTemplate> <ino:AttributeMap orientKey="email" attributeID="mail" /> <ino:AttributeMap orientKey="telephone" attributeID="homePhone" /> </resolver:DataConnector> |
<resolver:AttributeDefinition ...>
elements to make them use the OrientDB connector by making sure their <resolver:Dependency ...>
element point to the correct connector. For instance:
<resolver:AttributeDefinition id="uid" xsi:type="Simple" xmlns="urn:mace:shibboleth:2.0:resolver:ad" sourceAttributeID="uid"> <resolver:Dependency ref="myOrient" /> <resolver:AttributeEncoder xsi:type="SAML1String" xmlns="urn:mace:shibboleth:2.0:attribute:encoder" name="urn:mace:dir:attribute-def:uid" /> <resolver:AttributeEncoder xsi:type="SAML2String" xmlns="urn:mace:shibboleth:2.0:attribute:encoder" name="urn:oid:0.9.2342.19200300.100.1.1" friendlyName="uid" /> </resolver:AttributeDefinition> |
To enable logging, add the following in $IDP_CONFIG_DIR/logging.xml
<logger name="ca.inocybe.shibboleth" level="INFO" /> |
Contact jonathan.tellier@gmail.com