KeyStore.
The store can either be loaded by Vert.x from the filesystem:
HttpServerOptions options = HttpServerOptions.httpServerOptions();
options.setKeyCertOptions(new KeyStoreOptions().setType("JKS").setPath("/mykeystore.jks").setPassword("foo"));
Or directly provided as a buffer:
Buffer store = vertx.fileSystem().readFileBlocking("/mykeystore.jks");
options.setKeyCertOptions(new KeyStoreOptions().setType("JKS").setValue(store).setPassword("foo"));
You can also use specific subclasses JksOptions or PfxOptions that will set
the setType for you:
HttpServerOptions options = HttpServerOptions.httpServerOptions();
options.setKeyCertOptions(new JksOptions().setPath("/mykeystore.jks").setPassword("foo"));
| Access | Constructor and Description |
|---|---|
| public | |
| public | |
| public | KeyStoreOptions(JsonObject
the JSON json)
References Deprecated
JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.
Create options from JSON |
| Modifier and Type | Method and Description |
|---|---|
| public KeyStoreOptions | copy()
Implements abstract io. Implements io.
|
| public String | Returns: the store providerOverrides io.
|
| public String | |
| public KeyStoreOptions | setAlias(String alias)
Overrides io. Set the alias for a server certificate when the keystore has more than one. |
| public KeyStoreOptions | setAliasPassword(String aliasPassword)
Overrides io. Set the password for the server certificate designated by |
| public KeyStoreOptions | setPassword(String
the password password)Overrides io. Set the password for the key store |
| public KeyStoreOptions | setPath(String
the path path)Overrides io. Set the path to the key store |
| public KeyStoreOptions | Returns: a reference to this, so the API can be used fluentlythe type provider)Overrides io. Set the store provider. |
| public KeyStoreOptions | Returns: a reference to this, so the API can be used fluentlythe type type)Overrides io. Set the store type. |
| public KeyStoreOptions | setValue(Buffer
the key store as a buffer value)Overrides io.
References Deprecated
Buffer is deprecated or references (maybe indirectly) at least one deprecated element.
Set the key store as a buffer |
| public JsonObject | Returns: the JSON
References Deprecated
JsonObject is deprecated or references (maybe indirectly) at least one deprecated element.
Convert to JSON |
| KeyStoreOptions | back to summary |
|---|---|
| public KeyStoreOptions() Default constructor | |
| KeyStoreOptions | back to summary |
|---|---|
| public KeyStoreOptions(KeyStoreOptions other) Copy constructor
| |
| KeyStoreOptions | back to summary |
|---|---|
| public KeyStoreOptions(JsonObject json)
References Deprecated
See corresponding docs for further information. Create options from JSON
| |
| copy | back to summary |
|---|---|
| public KeyStoreOptions copy() Implements abstract io. Implements io.
| |
| getProvider | back to summary |
|---|---|
| public String getProvider() Overrides io.
| |
| getType | back to summary |
|---|---|
| public String getType() Overrides io.
| |
| setAlias | back to summary |
|---|---|
| public KeyStoreOptions setAlias(String alias) Overrides io. Doc from io. Set the alias for a server certificate when the keystore has more than one.
| |
| setAliasPassword | back to summary |
|---|---|
| public KeyStoreOptions setAliasPassword(String aliasPassword) Overrides io. Doc from io. Set the password for the server certificate designated by
| |
| setPassword | back to summary |
|---|---|
| public KeyStoreOptions setPassword(String password) Overrides io. Doc from io. Set the password for the key store
| |
| setPath | back to summary |
|---|---|
| public KeyStoreOptions setPath(String path) Overrides io. Doc from io. Set the path to the key store
| |
| setProvider | back to summary |
|---|---|
| public KeyStoreOptions setProvider(String provider) Overrides io. Set the store provider.
| |
| setType | back to summary |
|---|---|
| public KeyStoreOptions setType(String type) Overrides io. Set the store type.
| |
| setValue | back to summary |
|---|---|
| public KeyStoreOptions setValue(Buffer value) Overrides io. Doc from io. References Deprecated
See corresponding docs for further information. Set the key store as a buffer
| |
| toJson | back to summary |
|---|---|
| public JsonObject toJson()
References Deprecated
See corresponding docs for further information. Convert to JSON
| |