001/* 002 * The contents of this file are subject to the terms of the Common Development and 003 * Distribution License (the License). You may not use this file except in compliance with the 004 * License. 005 * 006 * You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the 007 * specific language governing permission and limitations under the License. 008 * 009 * When distributing Covered Software, include this CDDL Header Notice in each file and include 010 * the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL 011 * Header, with the fields enclosed by brackets [] replaced by your own identifying 012 * information: "Portions Copyright [year] [name of copyright owner]". 013 * 014 * Copyright 2008 Sun Microsystems, Inc. 015 */ 016package org.forgerock.opendj.server.config.client; 017 018 019 020import org.forgerock.opendj.config.ManagedObjectDefinition; 021import org.forgerock.opendj.config.PropertyException; 022import org.forgerock.opendj.server.config.meta.BackendCfgDefn.WritabilityMode; 023import org.forgerock.opendj.server.config.server.TrustStoreBackendCfg; 024 025 026 027/** 028 * A client-side interface for reading and modifying Trust Store 029 * Backend settings. 030 * <p> 031 * The Trust Store Backend provides an LDAP view of a file-based trust 032 * store. It is used by the administrative cryptographic framework. 033 */ 034public interface TrustStoreBackendCfgClient extends BackendCfgClient { 035 036 /** 037 * Get the configuration definition associated with this Trust Store Backend. 038 * 039 * @return Returns the configuration definition associated with this Trust Store Backend. 040 */ 041 ManagedObjectDefinition<? extends TrustStoreBackendCfgClient, ? extends TrustStoreBackendCfg> definition(); 042 043 044 045 /** 046 * Gets the "java-class" property. 047 * <p> 048 * Specifies the fully-qualified name of the Java class that 049 * provides the backend implementation. 050 * 051 * @return Returns the value of the "java-class" property. 052 */ 053 String getJavaClass(); 054 055 056 057 /** 058 * Sets the "java-class" property. 059 * <p> 060 * Specifies the fully-qualified name of the Java class that 061 * provides the backend implementation. 062 * 063 * @param value The value of the "java-class" property. 064 * @throws PropertyException 065 * If the new value is invalid. 066 */ 067 void setJavaClass(String value) throws PropertyException; 068 069 070 071 /** 072 * Gets the "trust-store-file" property. 073 * <p> 074 * Specifies the path to the file that stores the trust information. 075 * <p> 076 * It may be an absolute path, or a path that is relative to the 077 * OpenDJ instance root. 078 * 079 * @return Returns the value of the "trust-store-file" property. 080 */ 081 String getTrustStoreFile(); 082 083 084 085 /** 086 * Sets the "trust-store-file" property. 087 * <p> 088 * Specifies the path to the file that stores the trust information. 089 * <p> 090 * It may be an absolute path, or a path that is relative to the 091 * OpenDJ instance root. 092 * 093 * @param value The value of the "trust-store-file" property. 094 * @throws PropertyException 095 * If the new value is invalid. 096 */ 097 void setTrustStoreFile(String value) throws PropertyException; 098 099 100 101 /** 102 * Gets the "trust-store-pin" property. 103 * <p> 104 * Specifies the clear-text PIN needed to access the Trust Store 105 * Backend . 106 * 107 * @return Returns the value of the "trust-store-pin" property. 108 */ 109 String getTrustStorePin(); 110 111 112 113 /** 114 * Sets the "trust-store-pin" property. 115 * <p> 116 * Specifies the clear-text PIN needed to access the Trust Store 117 * Backend . 118 * 119 * @param value The value of the "trust-store-pin" property. 120 * @throws PropertyException 121 * If the new value is invalid. 122 */ 123 void setTrustStorePin(String value) throws PropertyException; 124 125 126 127 /** 128 * Gets the "trust-store-pin-environment-variable" property. 129 * <p> 130 * Specifies the name of the environment variable that contains the 131 * clear-text PIN needed to access the Trust Store Backend . 132 * 133 * @return Returns the value of the "trust-store-pin-environment-variable" property. 134 */ 135 String getTrustStorePinEnvironmentVariable(); 136 137 138 139 /** 140 * Sets the "trust-store-pin-environment-variable" property. 141 * <p> 142 * Specifies the name of the environment variable that contains the 143 * clear-text PIN needed to access the Trust Store Backend . 144 * 145 * @param value The value of the "trust-store-pin-environment-variable" property. 146 * @throws PropertyException 147 * If the new value is invalid. 148 */ 149 void setTrustStorePinEnvironmentVariable(String value) throws PropertyException; 150 151 152 153 /** 154 * Gets the "trust-store-pin-file" property. 155 * <p> 156 * Specifies the path to the text file whose only contents should be 157 * a single line containing the clear-text PIN needed to access the 158 * Trust Store Backend . 159 * 160 * @return Returns the value of the "trust-store-pin-file" property. 161 */ 162 String getTrustStorePinFile(); 163 164 165 166 /** 167 * Sets the "trust-store-pin-file" property. 168 * <p> 169 * Specifies the path to the text file whose only contents should be 170 * a single line containing the clear-text PIN needed to access the 171 * Trust Store Backend . 172 * 173 * @param value The value of the "trust-store-pin-file" property. 174 * @throws PropertyException 175 * If the new value is invalid. 176 */ 177 void setTrustStorePinFile(String value) throws PropertyException; 178 179 180 181 /** 182 * Gets the "trust-store-pin-property" property. 183 * <p> 184 * Specifies the name of the Java property that contains the 185 * clear-text PIN needed to access the Trust Store Backend . 186 * 187 * @return Returns the value of the "trust-store-pin-property" property. 188 */ 189 String getTrustStorePinProperty(); 190 191 192 193 /** 194 * Sets the "trust-store-pin-property" property. 195 * <p> 196 * Specifies the name of the Java property that contains the 197 * clear-text PIN needed to access the Trust Store Backend . 198 * 199 * @param value The value of the "trust-store-pin-property" property. 200 * @throws PropertyException 201 * If the new value is invalid. 202 */ 203 void setTrustStorePinProperty(String value) throws PropertyException; 204 205 206 207 /** 208 * Gets the "trust-store-type" property. 209 * <p> 210 * Specifies the format for the data in the key store file. 211 * <p> 212 * Valid values should always include 'JKS' and 'PKCS12', but 213 * different implementations may allow other values as well. 214 * 215 * @return Returns the value of the "trust-store-type" property. 216 */ 217 String getTrustStoreType(); 218 219 220 221 /** 222 * Sets the "trust-store-type" property. 223 * <p> 224 * Specifies the format for the data in the key store file. 225 * <p> 226 * Valid values should always include 'JKS' and 'PKCS12', but 227 * different implementations may allow other values as well. 228 * 229 * @param value The value of the "trust-store-type" property. 230 * @throws PropertyException 231 * If the new value is invalid. 232 */ 233 void setTrustStoreType(String value) throws PropertyException; 234 235 236 237 /** 238 * Gets the "writability-mode" property. 239 * <p> 240 * Specifies the behavior that the backend should use when 241 * processing write operations. 242 * 243 * @return Returns the value of the "writability-mode" property. 244 */ 245 WritabilityMode getWritabilityMode(); 246 247 248 249 /** 250 * Sets the "writability-mode" property. 251 * <p> 252 * Specifies the behavior that the backend should use when 253 * processing write operations. 254 * 255 * @param value The value of the "writability-mode" property. 256 * @throws PropertyException 257 * If the new value is invalid. 258 */ 259 void setWritabilityMode(WritabilityMode value) throws PropertyException; 260 261}