From d25e598b7ff395b7ebfcaecfa4263c70999559de Mon Sep 17 00:00:00 2001 From: Plamen Jeliazkov Date: Fri, 13 Jul 2018 10:55:29 -0700 Subject: [PATCH] [#75] Re-organize configuration properties --- src/main/resources/config/security.properties | 16 +++++++++---- src/test/resources/security.properties | 24 ++++++++++++------- 2 files changed, 26 insertions(+), 14 deletions(-) diff --git a/src/main/resources/config/security.properties b/src/main/resources/config/security.properties index 24516b86..abdd21f0 100644 --- a/src/main/resources/config/security.properties +++ b/src/main/resources/config/security.properties @@ -23,9 +23,11 @@ nna.port=8080 # Whether NNA should manage embedded DB for /history. nna.historical=false +# How long to sleep in-between NNA reports in milliseconds. +nna.suggestions.reload.sleep.ms=900000 + # Turn on / off LDAP authentication. ldap.enable=false -authorization.enable=false # Standard LDAP connection properties. ## BaseDn's %u will be replaced with username. @@ -49,10 +51,14 @@ ssl.keystore.password=password jwt.signature.secret=11111111111111111111111111111111 jwt.encryption.secret=0000000000000000 -# LDAP Whitelist (This is refresh-able). -## Admin users can make changes to NNA. -## Write users can issues commands that modify the actual HDFS namespace. -## Read-only users can only run queries via NNA. +# Turn on / off NNA authorization and ACLs. +authorization.enable=false + +# NNA Authorization ACLs (This is refresh-able during runtime). +## Admin users can make changes to NNA like fetching, saving, and reloading namespace. +## Write users can issues commands that modify the live HDFS cluster. +## Read-only users can run read-only queries via NNA. +## Cache users only have access to cached NNA reports. ## Any user outside these lists cannot use any function of NNA. ## An * will mean all users have this access. nna.localonly.users=hdfs:hdfs diff --git a/src/test/resources/security.properties b/src/test/resources/security.properties index 0e99ec09..64f4cc52 100644 --- a/src/test/resources/security.properties +++ b/src/test/resources/security.properties @@ -23,9 +23,11 @@ nna.port=4567 # Whether NNA should manage embedded DB for /history. nna.historical=false -# Turn on / off LDAP authentication and authorization. +# How long to sleep in-between NNA reports in milliseconds. +nna.suggestions.reload.sleep.ms=30000 + +# Turn on / off LDAP authentication. ldap.enable=true -authorization.enable=true # Standard LDAP connection properties. ## BaseDn's %u will be replaced with username. @@ -41,8 +43,8 @@ ldap.connection.pool.min.size=1 ldap.connection.pool.max.size=2 # Standard SSL properties. -#ssl.keystore.path= -#ssl.keystore.password= +#ssl.keystore.path=file:/tmp/keystore +#ssl.keystore.password=password # Standard JWT properties. ## Signature defaults to JWSAlgorithm.HS256. @@ -50,14 +52,18 @@ ldap.connection.pool.max.size=2 jwt.signature.secret=11111111111111111111111111111111 jwt.encryption.secret=0000000000000000 -# LDAP Whitelist (This is refresh-able). -## Admin users can make changes to NNA. -## Write users can issues commands that modify the actual HDFS namespace. -## Read-only users can only run queries via NNA. +# Turn on / off NNA authorization and ACLs. +authorization.enable=true + +# NNA Authorization ACLs (This is refresh-able during runtime). +## Admin users can make changes to NNA like fetching, saving, and reloading namespace. +## Write users can issues commands that modify the live HDFS cluster. +## Read-only users can run read-only queries via NNA. +## Cache users only have access to cached NNA reports. ## Any user outside these lists cannot use any function of NNA. +## An * will mean all users have this access. nna.localonly.users=hdfs:hdfs,hdfsW:hdfsW,hdfsR:hdfsR nna.admin.users=hdfs nna.write.users=hdfsW nna.readonly.users=hdfsR nna.cache.users=hdfsR,hdfs -nna.suggestions.reload.sleep.ms=30000