From 66f5a006623b537bbd1285e14626f7fbd789b471 Mon Sep 17 00:00:00 2001 From: Lalith Kota Date: Tue, 23 Apr 2024 01:23:54 +0530 Subject: [PATCH 1/2] Fixed crypto admin group access and fixed update prov bug Signed-off-by: Lalith Kota --- g2p_encryption/static/description/index.html | 7 +- .../static/description/index.html | 7 +- .../static/description/index.html | 7 +- g2p_registry_encryption/models/partner.py | 2 +- .../static/description/index.html | 7 +- .../views/res_config_view.xml | 72 ++++++++++--------- 6 files changed, 54 insertions(+), 48 deletions(-) diff --git a/g2p_encryption/static/description/index.html b/g2p_encryption/static/description/index.html index 7ec4129..7871dd9 100644 --- a/g2p_encryption/static/description/index.html +++ b/g2p_encryption/static/description/index.html @@ -8,10 +8,11 @@ /* :Author: David Goodger (goodger@python.org) -:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $ +:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $ :Copyright: This stylesheet has been placed in the public domain. Default cascading style sheet for the HTML output of Docutils. +Despite the name, some widely supported CSS2 features are used. See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to customize this style sheet. @@ -274,7 +275,7 @@ margin-left: 2em ; margin-right: 2em } -pre.code .ln { color: grey; } /* line numbers */ +pre.code .ln { color: gray; } /* line numbers */ pre.code, code { background-color: #eeeeee } pre.code .comment, code .comment { color: #5C6576 } pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold } @@ -300,7 +301,7 @@ span.pre { white-space: pre } -span.problematic { +span.problematic, pre.problematic { color: red } span.section-subtitle { diff --git a/g2p_encryption_keymanager/static/description/index.html b/g2p_encryption_keymanager/static/description/index.html index 3425e96..8e01df3 100644 --- a/g2p_encryption_keymanager/static/description/index.html +++ b/g2p_encryption_keymanager/static/description/index.html @@ -8,10 +8,11 @@ /* :Author: David Goodger (goodger@python.org) -:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $ +:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $ :Copyright: This stylesheet has been placed in the public domain. Default cascading style sheet for the HTML output of Docutils. +Despite the name, some widely supported CSS2 features are used. See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to customize this style sheet. @@ -274,7 +275,7 @@ margin-left: 2em ; margin-right: 2em } -pre.code .ln { color: grey; } /* line numbers */ +pre.code .ln { color: gray; } /* line numbers */ pre.code, code { background-color: #eeeeee } pre.code .comment, code .comment { color: #5C6576 } pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold } @@ -300,7 +301,7 @@ span.pre { white-space: pre } -span.problematic { +span.problematic, pre.problematic { color: red } span.section-subtitle { diff --git a/g2p_encryption_rest_api/static/description/index.html b/g2p_encryption_rest_api/static/description/index.html index dd43918..1d70951 100644 --- a/g2p_encryption_rest_api/static/description/index.html +++ b/g2p_encryption_rest_api/static/description/index.html @@ -8,10 +8,11 @@ /* :Author: David Goodger (goodger@python.org) -:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $ +:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $ :Copyright: This stylesheet has been placed in the public domain. Default cascading style sheet for the HTML output of Docutils. +Despite the name, some widely supported CSS2 features are used. See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to customize this style sheet. @@ -274,7 +275,7 @@ margin-left: 2em ; margin-right: 2em } -pre.code .ln { color: grey; } /* line numbers */ +pre.code .ln { color: gray; } /* line numbers */ pre.code, code { background-color: #eeeeee } pre.code .comment, code .comment { color: #5C6576 } pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold } @@ -300,7 +301,7 @@ span.pre { white-space: pre } -span.problematic { +span.problematic, pre.problematic { color: red } span.section-subtitle { diff --git a/g2p_registry_encryption/models/partner.py b/g2p_registry_encryption/models/partner.py index dcf72c7..fd223df 100644 --- a/g2p_registry_encryption/models/partner.py +++ b/g2p_registry_encryption/models/partner.py @@ -62,7 +62,7 @@ def write(self, vals): vals = rec_values_list else: vals = json.loads(prov.decrypt_data(encrypted_val).decode()).update(vals) - to_be_encrypted = self.gather_fields_to_be_enc_from_dict(vals) + to_be_encrypted = self.gather_fields_to_be_enc_from_dict(vals, prov) vals["encrypted_val"] = prov.encrypt_data(json.dumps(to_be_encrypted).encode()) diff --git a/g2p_registry_encryption/static/description/index.html b/g2p_registry_encryption/static/description/index.html index 3bc7112..a85263d 100644 --- a/g2p_registry_encryption/static/description/index.html +++ b/g2p_registry_encryption/static/description/index.html @@ -8,10 +8,11 @@ /* :Author: David Goodger (goodger@python.org) -:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $ +:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $ :Copyright: This stylesheet has been placed in the public domain. Default cascading style sheet for the HTML output of Docutils. +Despite the name, some widely supported CSS2 features are used. See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to customize this style sheet. @@ -274,7 +275,7 @@ margin-left: 2em ; margin-right: 2em } -pre.code .ln { color: grey; } /* line numbers */ +pre.code .ln { color: gray; } /* line numbers */ pre.code, code { background-color: #eeeeee } pre.code .comment, code .comment { color: #5C6576 } pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold } @@ -300,7 +301,7 @@ span.pre { white-space: pre } -span.problematic { +span.problematic, pre.problematic { color: red } span.section-subtitle { diff --git a/g2p_registry_encryption/views/res_config_view.xml b/g2p_registry_encryption/views/res_config_view.xml index 9fce9c9..8de8c8f 100644 --- a/g2p_registry_encryption/views/res_config_view.xml +++ b/g2p_registry_encryption/views/res_config_view.xml @@ -7,43 +7,45 @@ -

G2P Registry Encryption Settings

-
-
-
-