X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=openflow-protocol-api%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fopenflowjava%2Fprotocol%2Fapi%2Fconnection%2FTlsConfigurationImpl.java;h=78a6c6b8c1804b0132a719884bca80706961114a;hb=519a86d1ddcfb8f0fe264174e62e5424e1efba1f;hp=4d6fa87d7ef469393251fa92264e957a6e2ef2f3;hpb=e1c384c30000127fd6b266d90471a996ffa5bd83;p=openflowjava.git diff --git a/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/connection/TlsConfigurationImpl.java b/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/connection/TlsConfigurationImpl.java index 4d6fa87d..78a6c6b8 100644 --- a/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/connection/TlsConfigurationImpl.java +++ b/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/connection/TlsConfigurationImpl.java @@ -1,91 +1,91 @@ -/* - * Copyright (c) 2014 Pantheon Technologies s.r.o. and others. All rights reserved. - * - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0 which accompanies this distribution, - * and is available at http://www.eclipse.org/legal/epl-v10.html - */ - -package org.opendaylight.openflowjava.protocol.api.connection; - -import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.config.rev140630.KeystoreType; -import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.config.rev140630.PathType; - -/** - * Class is used only for testing purposes - passwords are hardcoded - * @author michal.polkorab - */ -public class TlsConfigurationImpl implements TlsConfiguration { - - private KeystoreType trustStoreType; - private String trustStore; - private KeystoreType keyStoreType; - private String keyStore; - private PathType keystorePathType; - private PathType truststorePathType; - - /** - * Default constructor - * @param trustStoreType JKS or PKCS12 - * @param trustStore path to trustStore file - * @param trustStorePathType truststore path type (classpath or path) - * @param keyStoreType JKS or PKCS12 - * @param keyStore path to keyStore file - * @param keyStorePathType keystore path type (classpath or path) - */ - public TlsConfigurationImpl(KeystoreType trustStoreType, String trustStore, - PathType trustStorePathType, KeystoreType keyStoreType, - String keyStore, PathType keyStorePathType) { - this.trustStoreType = trustStoreType; - this.trustStore = trustStore; - this.truststorePathType = trustStorePathType; - this.keyStoreType = keyStoreType; - this.keyStore = keyStore; - this.keystorePathType = keyStorePathType; - } - - @Override - public KeystoreType getTlsTruststoreType() { - return trustStoreType; - } - - @Override - public String getTlsTruststore() { - return trustStore; - } - - @Override - public KeystoreType getTlsKeystoreType() { - return keyStoreType; - } - - @Override - public String getTlsKeystore() { - return keyStore; - } - - @Override - public PathType getTlsKeystorePathType() { - return keystorePathType; - } - - @Override - public PathType getTlsTruststorePathType() { - return truststorePathType; - } - - @Override - public String getKeystorePassword() { - return "opendaylight"; - } - - @Override - public String getCertificatePassword() { - return "opendaylight"; - } - - @Override - public String getTruststorePassword() { - return "opendaylight"; - } -} +/* + * Copyright (c) 2014 Pantheon Technologies s.r.o. and others. All rights reserved. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Public License v1.0 which accompanies this distribution, + * and is available at http://www.eclipse.org/legal/epl-v10.html + */ + +package org.opendaylight.openflowjava.protocol.api.connection; + +import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.config.rev140630.KeystoreType; +import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.config.rev140630.PathType; + +/** + * Class is used only for testing purposes - passwords are hardcoded + * @author michal.polkorab + */ +public class TlsConfigurationImpl implements TlsConfiguration { + + private KeystoreType trustStoreType; + private String trustStore; + private KeystoreType keyStoreType; + private String keyStore; + private PathType keystorePathType; + private PathType truststorePathType; + + /** + * Default constructor + * @param trustStoreType JKS or PKCS12 + * @param trustStore path to trustStore file + * @param trustStorePathType truststore path type (classpath or path) + * @param keyStoreType JKS or PKCS12 + * @param keyStore path to keyStore file + * @param keyStorePathType keystore path type (classpath or path) + */ + public TlsConfigurationImpl(KeystoreType trustStoreType, String trustStore, + PathType trustStorePathType, KeystoreType keyStoreType, + String keyStore, PathType keyStorePathType) { + this.trustStoreType = trustStoreType; + this.trustStore = trustStore; + this.truststorePathType = trustStorePathType; + this.keyStoreType = keyStoreType; + this.keyStore = keyStore; + this.keystorePathType = keyStorePathType; + } + + @Override + public KeystoreType getTlsTruststoreType() { + return trustStoreType; + } + + @Override + public String getTlsTruststore() { + return trustStore; + } + + @Override + public KeystoreType getTlsKeystoreType() { + return keyStoreType; + } + + @Override + public String getTlsKeystore() { + return keyStore; + } + + @Override + public PathType getTlsKeystorePathType() { + return keystorePathType; + } + + @Override + public PathType getTlsTruststorePathType() { + return truststorePathType; + } + + @Override + public String getKeystorePassword() { + return "opendaylight"; + } + + @Override + public String getCertificatePassword() { + return "opendaylight"; + } + + @Override + public String getTruststorePassword() { + return "opendaylight"; + } +}