Class KerberosSecurityTestcase
java.lang.Object
org.springframework.security.kerberos.test.KerberosSecurityTestcase
KerberosSecurityTestcase provides a base class for using MiniKdc with other testcases.
KerberosSecurityTestcase starts the MiniKdc (@BeforeEach) before running tests, and
stop the MiniKdc (@AfterEach) after the testcases, using default settings (working dir
and kdc configurations).
Users can directly inherit this class and implement their own test functions using the default settings, or override functions getTestDir() and createMiniKdcConf() to provide new settings.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCreate a Kdc configurationvoidCreate a working directory, it should be the build directory.@Nullable PropertiesgetConf()@Nullable MiniKdcgetKdc()@Nullable Filevoidvoid
-
Constructor Details
-
KerberosSecurityTestcase
public KerberosSecurityTestcase()
-
-
Method Details
-
startMiniKdc
-
createTestDir
public void createTestDir()Create a working directory, it should be the build directory. Under this directory an ApacheDS working directory will be created, this directory will be deleted when the MiniKdc stops. -
createMiniKdcConf
public void createMiniKdcConf()Create a Kdc configuration -
stopMiniKdc
@AfterEach public void stopMiniKdc() -
getKdc
-
getWorkDir
-
getConf
-