apache / apache/mina-ftpserver

setKeystoreFile for a resource file in class path

Open
#78 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
67
Forks
38
PR merge metrics
No merged PRs in 30d

Description

org.apache.ftpserver.ssl.SslConfigurationFactory#loadStore support file or resource.

but org.apache.ftpserver.ssl.SslConfigurationFactory#setKeystoreFile only support file , it will check file length:

```
public void setKeystoreFile(File keyStoreFile) {
if (keyStoreFile != null && keyStoreFile.length() != 0L) {
this.keystoreFile = keyStoreFile;
} else {
throw new FtpServerConfigurationException("KeystoreFile must not be null or zero length");
}
}

```
resolve this is to remove the check :

```
public void setKeystoreFile(File keyStoreFile) {

this.keystoreFile = keyStoreFile;

}
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.