Hi,
I wrote this route :
@Component
public class MassPaymentInRoute extends SpringRouteBuilder {
@Value("${user.password}")
String cryptedPwd;
String decryptedPwd;
@Override
public void configure() {
Cipher cs = new Cipher();
try {
decryptedPwd = cs.decrypt(cryptedPwd);
getContext().getProperties().put("*decPwd*", decryptedPwd);
// getContext().
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
.from("{{source.endpoint.1}}")
etc.....
The value {{source.endpoint.1}} is defined in a properties file :
source.endpoint.1=ftp://${user.name}:${properties:{{decPwd}}@xxxxxx//echange/MassPayment/IN/?noop=false詸궉ꥃ穖=0觗ꚦ譞=true닗꧂⬞=false
but when i run it , i get this message :
"Property with key [decPwd] not found in properties from text"
I also try to use the function decrypt directly in the properties file, like
this :
source.endpoint.1=ftp://${user.name}:#{cipher.decrypt('${user.password}')}@xxxxxx//echange/MassPayment/IN/?noop=false詸궉ꥃ穖=0觗ꚦ譞=true닗꧂⬞=false
cipher is defined in the camel context
but it doesn't work...
What is the best way to get my password decrypted ?
thank's in advance
I wrote this route :
@Component
public class MassPaymentInRoute extends SpringRouteBuilder {
@Value("${user.password}")
String cryptedPwd;
String decryptedPwd;
@Override
public void configure() {
Cipher cs = new Cipher();
try {
decryptedPwd = cs.decrypt(cryptedPwd);
getContext().getProperties().put("*decPwd*", decryptedPwd);
// getContext().
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
.from("{{source.endpoint.1}}")
etc.....
The value {{source.endpoint.1}} is defined in a properties file :
source.endpoint.1=ftp://${user.name}:${properties:{{decPwd}}@xxxxxx//echange/MassPayment/IN/?noop=false詸궉ꥃ穖=0觗ꚦ譞=true닗꧂⬞=false
but when i run it , i get this message :
"Property with key [decPwd] not found in properties from text"
I also try to use the function decrypt directly in the properties file, like
this :
source.endpoint.1=ftp://${user.name}:#{cipher.decrypt('${user.password}')}@xxxxxx//echange/MassPayment/IN/?noop=false詸궉ꥃ穖=0觗ꚦ譞=true닗꧂⬞=false
cipher is defined in the camel context
but it doesn't work...
What is the best way to get my password decrypted ?
thank's in advance