Class ScepTransport
java.lang.Object
zeroecho.pki.server.http.ScepTransport
- All Implemented Interfaces:
AutoCloseable
Lifecycle owner for the optional SCEP RFC 8894 HTTPS listener.
SCEP does not require mutual TLS at the transport layer; authentication is carried inside the SCEP PKIMessage via the challenge password. The listener still requires HTTPS for confidentiality.
Usage: start(PkiServerConfiguration.ScepListener, ServerRealmContext, SecureRandom, ClassLoader, BooleanSupplier) returns a fully running transport; call shutdown(Duration)
or close() to stop it.
- Since:
- 1.0
-
Method Summary
Modifier and TypeMethodDescriptionaddress()Returns the actual listener address, including an allocated ephemeral port.voidclose()voidquiesce()Rejects new protocol work.service()Returns the SCEP service for administrative endpoint management.voidStops listener admission and the SCEP lane executors.static ScepTransportstart(PkiServerConfiguration.ScepListener configuration, ServerRealmContext realm, SecureRandom random, ClassLoader loader, BooleanSupplier ready) Starts one SCEP listener over the lifecycle-owned realm and PKI session.
-
Method Details
-
start
public static ScepTransport start(PkiServerConfiguration.ScepListener configuration, ServerRealmContext realm, SecureRandom random, ClassLoader loader, BooleanSupplier ready) Starts one SCEP listener over the lifecycle-owned realm and PKI session.- Parameters:
configuration- validated SCEP listener configurationrealm- shared lifecycle-owned realmrandom- cryptographically secure entropy sourceloader- provider service class loaderready- readiness predicate checked by request handlers- Returns:
- started SCEP listener lifecycle owner
- Throws:
IllegalStateException- if the listener cannot be initialized
-
address
Returns the actual listener address, including an allocated ephemeral port.- Returns:
- bound listener address
-
service
Returns the SCEP service for administrative endpoint management.- Returns:
- the SCEP service holding the endpoint registry
-
quiesce
public void quiesce()Rejects new protocol work. -
shutdown
Stops listener admission and the SCEP lane executors.- Parameters:
graceful- maximum transport drain duration; whole seconds are passed to the listener
-
close
public void close()- Specified by:
closein interfaceAutoCloseable
-