001/*
002 * (C) Copyright 2014 Nuxeo SA (http://nuxeo.com/) and contributors.
003 *
004 * All rights reserved. This program and the accompanying materials
005 * are made available under the terms of the GNU Lesser General Public License
006 * (LGPL) version 2.1 which accompanies this distribution, and is available at
007 * http://www.gnu.org/licenses/lgpl-2.1.html
008 *
009 * This library is distributed in the hope that it will be useful,
010 * but WITHOUT ANY WARRANTY; without even the implied warranty of
011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
012 * Lesser General Public License for more details.
013 *
014 * Contributors:
015 *     Nelson Silva <nelson.silva@inevo.pt>
016 */
017package org.nuxeo.ecm.platform.auth.saml.key;
018
019import org.nuxeo.common.xmap.annotation.XNode;
020import org.nuxeo.common.xmap.annotation.XNodeMap;
021import org.nuxeo.common.xmap.annotation.XObject;
022
023import java.util.HashMap;
024import java.util.Map;
025
026@XObject("configuration")
027public class KeyDescriptor {
028
029    @XNode("keystoreFilePath")
030    protected String keystoreFilePath;
031
032    @XNode("keystorePassword")
033    protected String keystorePassword;
034
035    @XNode("signingKey")
036    protected String signingKey;
037
038    @XNode("encryptionKey")
039    protected String encryptionKey;
040
041    @XNode("tlsKey")
042    protected String tlsKey;
043
044    @XNodeMap(value = "passwords/password", key = "@key", type = HashMap.class, componentType = String.class)
045    protected Map<String, String> passwords;
046
047    public String getKeystoreFilePath() {
048        return keystoreFilePath;
049    }
050
051    public String getKeystorePassword() {
052        return keystorePassword;
053    }
054
055    public Map<String, String> getPasswords() {
056        return passwords;
057    }
058
059    public String getSigningKey() {
060        return signingKey;
061    }
062
063    public String getEncryptionKey() {
064        return encryptionKey;
065    }
066
067    public String getTlsKey() {
068        return tlsKey;
069    }
070}