-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #17 from 3KeyCompany/release/1.2.0
Release version 1.2.0
- Loading branch information
Showing
17 changed files
with
236 additions
and
153 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
src/main/java/com/czertainly/cp/soft/attribute/RsaCipherAttributes.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package com.czertainly.cp.soft.attribute; | ||
|
||
public class RsaCipherAttributes { | ||
public static final String ATTRIBUTE_DATA_RSA_ENC_SCHEME_NAME = "data_rsaEncScheme"; | ||
public static final String ATTRIBUTE_DATA_RSA_OAEP_HASH_NAME = "data_rsaOaepHash"; | ||
public static final String ATTRIBUTE_DATA_RSA_OAEP_USE_MGF_NAME = "data_rsaOaepMgf"; | ||
} |
88 changes: 0 additions & 88 deletions
88
src/main/java/com/czertainly/cp/soft/collection/KeyAlgorithm.java
This file was deleted.
Oops, something went wrong.
22 changes: 22 additions & 0 deletions
22
src/main/java/com/czertainly/cp/soft/config/WebAppConfig.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
package com.czertainly.cp.soft.config; | ||
|
||
import com.czertainly.api.model.common.enums.cryptography.KeyAlgorithm; | ||
import org.springframework.context.annotation.ComponentScan; | ||
import org.springframework.context.annotation.Configuration; | ||
import org.springframework.core.convert.converter.Converter; | ||
import org.springframework.format.FormatterRegistry; | ||
import org.springframework.web.servlet.config.annotation.EnableWebMvc; | ||
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; | ||
|
||
@Configuration | ||
public class WebAppConfig implements WebMvcConfigurer { | ||
@Override | ||
public void addFormatters(FormatterRegistry registry) { | ||
registry.addConverter(new Converter<String, KeyAlgorithm>() { | ||
@Override | ||
public KeyAlgorithm convert(String source) { | ||
return KeyAlgorithm.findByCode(source); | ||
} | ||
}); | ||
} | ||
} |
26 changes: 0 additions & 26 deletions
26
src/main/java/com/czertainly/cp/soft/dao/converter/CryptographicAlgorithmConverter.java
This file was deleted.
Oops, something went wrong.
26 changes: 26 additions & 0 deletions
26
src/main/java/com/czertainly/cp/soft/dao/converter/KeyAlgorithmConverter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
package com.czertainly.cp.soft.dao.converter; | ||
|
||
import com.czertainly.api.model.common.enums.cryptography.KeyAlgorithm; | ||
import jakarta.persistence.AttributeConverter; | ||
import jakarta.persistence.Converter; | ||
|
||
@Converter(autoApply = true) | ||
public class KeyAlgorithmConverter implements AttributeConverter<KeyAlgorithm, String> { | ||
|
||
@Override | ||
public String convertToDatabaseColumn(KeyAlgorithm keyAlgorithm) { | ||
if (keyAlgorithm == null) { | ||
return null; | ||
} | ||
return keyAlgorithm.name(); | ||
} | ||
|
||
@Override | ||
public KeyAlgorithm convertToEntityAttribute(String keyAlgorithm) { | ||
if (keyAlgorithm == null) { | ||
return null; | ||
} | ||
return KeyAlgorithm.valueOf(keyAlgorithm); | ||
} | ||
|
||
} |
2 changes: 1 addition & 1 deletion
2
src/main/java/com/czertainly/cp/soft/dao/converter/KeyFormatConverter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/com/czertainly/cp/soft/dao/converter/KeyTypeConverter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.