Conversation
… from a variety of sources, as well as supporting password decryption for passwords stored in encrypted form
… from a variety of sources, as well as supporting password decryption for passwords stored in encrypted form
… from a variety of sources, as well as supporting password decryption for passwords stored in encrypted form
…wave into GEOWAVE-811-rebase
| String value = existingProps.getProperty(storeFieldName); | ||
| String encryptedValue = value; | ||
| try { | ||
| encryptedValue = new SecurityUtils().encryptAndHexEncodeValue(value); |
There was a problem hiding this comment.
static method and pass in resourceLocation
|
|
||
| final String password = (System.getProperty("password") != null) ? System.getProperty("password") : "password"; | ||
| // GeoWave:811 - providing ability to support encrypted passwords | ||
| final String password = new SecurityUtils() |
There was a problem hiding this comment.
static method and pass in resourceLocation
| else { | ||
| try { | ||
| // if password in config props is encrypted, need to decrypt it | ||
| pass = new SecurityUtils().decryptHexEncodedValue(pass); |
There was a problem hiding this comment.
static method and pass in resourceLocation
| this.password = password; | ||
| // GeoWave:811 - providing ability to support encrypted passwords | ||
| try { | ||
| this.password = new SecurityUtils().decryptHexEncodedValue(password); |
There was a problem hiding this comment.
static method and pass in resourceLocation
| // final String password = (System.getProperty("password") != null) ? | ||
| // System.getProperty("password") : "password"; | ||
| // GeoWave:811 - providing ability to support encrypted passwords | ||
| final String password = new SecurityUtils() |
There was a problem hiding this comment.
static method and pass in resourceLocation
| ConfigOptions.writeProperties( | ||
| getGeoWaveConfigFile(params), | ||
| configProps); | ||
| System.out.println("GeoServer Config Saved"); |
There was a problem hiding this comment.
we can log if necessary, is there a reason for system.out here?
| String encryptedValue = new SecurityUtils().encryptAndHexEncodeValue( | ||
| rawInput, | ||
| tokenFile.getCanonicalPath()); | ||
| System.out.println("encryptedValue: " + encryptedValue); |
There was a problem hiding this comment.
we can log if necessary, is there a reason for system.out here?
| String decryptedValue = new SecurityUtils().decryptHexEncodedValue( | ||
| encryptedValue, | ||
| tokenFile.getCanonicalPath()); | ||
| System.out.println("decryptedValue: " + decryptedValue); |
There was a problem hiding this comment.
we can log if necessary, is there a reason for system.out here?
| gsConfig); | ||
| gsConfigProperties); | ||
|
|
||
| System.out.println("GeoServer Config Saved"); |
There was a problem hiding this comment.
we can log if necessary, is there a reason for system.out here?
There was a problem hiding this comment.
I can switch to a log statement. The system.out was there previously and I didn't think to change it
| + File.separator + ConfigOptions.GEOWAVE_CACHE_FILE)); | ||
| } | ||
|
|
||
| public String getUrl() { |
There was a problem hiding this comment.
now that we are checking for https within the client, it seems like it may make sense to use https:// on line 124 if we detect a port that ends with 443
…ng un-used methods. Adding a new URLUtils class which helps reduce redundant URL validation in a few places across codebase. Also adding feature to allow encryption to be enabled or disabled through configs. At this point, encryption should be done only when writing to the properties file, and then decrypted when loading from the properties. This should reduce the places where we are trying to decrypt values
No description provided.