Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Specify the file which cannot be decrypted when invalid master key file error is raised #481

Closed
fluca1978 opened this issue Nov 4, 2024 · 0 comments · Fixed by #483
Closed
Labels
feature New feature

Comments

@fluca1978
Copy link
Collaborator

When pgagroal starts, if it cannot decrypt a xxx_users.conf file information, it raises the Invalid master key file error.
This does not help in understand which file cannot be decrypted, hence it does not help in understanding which file has to be "adjusted" (via for example pgagroal-admin).
On the other hand, if one xxx_users.conf file is not found, the error message clearly shows which file is missing.

I propose to uniform the error messages, so that if a file cannot be decrypted, the error message (and optionally the systemd status message) includes the target file.

@fluca1978 fluca1978 added the feature New feature label Nov 4, 2024
fluca1978 added a commit to fluca1978/pgagroal that referenced this issue Nov 4, 2024
When a users file, (frontend, admins or users files) cannot be
decrypted, a generic `Invalid master key file` was raised.
This commit adds the target file that cannot be decrypted, so that the
user can understand which file has to be adjusted (e.g.,
`pgagroal-admin` usage on such file).

Makes the error messages consistent with those about a missing file.

Close agroal#481
fluca1978 added a commit that referenced this issue Nov 4, 2024
When a users file, (frontend, admins or users files) cannot be
decrypted, a generic `Invalid master key file` was raised.
This commit adds the target file that cannot be decrypted, so that the
user can understand which file has to be adjusted (e.g.,
`pgagroal-admin` usage on such file).

Makes the error messages consistent with those about a missing file.

Close #481
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant