Skip to content

Commit 90ef017

Browse files
authored
Land rapid7#19289, Update apache_nifi_credentials algo regex
2 parents dc667dc + eb0933f commit 90ef017

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

modules/post/linux/gather/apache_nifi_credentials.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,10 @@ def run
266266
key = properties.scan(/^nifi.sensitive.props.key=(.+)$/).flatten.first.strip
267267
fail_with(Failure::NotFound, 'Unable to find nifi.properties and/or flow.json.gz files') if key.nil?
268268
print_good("Key: #{key}")
269-
algorithm = properties.scan(/^nifi.sensitive.props.algorithm=(\w+)$/).flatten.first.strip
269+
# https://rubular.com/r/N0w0WHTjjdKXHZ
270+
# https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#property-encryption-algorithms
271+
# https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#java-cryptography-extension-jce-limited-strength-jurisdiction-policies
272+
algorithm = properties.scan(/^nifi.sensitive.props.algorithm=([\w-]+)$/).flatten.first.strip
270273
fail_with(Failure::NotFound, 'Unable to find nifi.properties and/or flow.json.gz files') if algorithm.nil?
271274

272275
columns = ['Name', 'Username', 'Password', 'Other Information']

0 commit comments

Comments
 (0)