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

PHP Fatal error: Uncaught Exception: get_key failed #2

Open
maaneeel opened this issue Dec 31, 2023 · 1 comment
Open

PHP Fatal error: Uncaught Exception: get_key failed #2

maaneeel opened this issue Dec 31, 2023 · 1 comment

Comments

@maaneeel
Copy link

Hello,

The login process fails with the following notice and error on the log:

[Sun Dec 31 15:54:42.587198 2023] [php7:notice] [pid 28228] [client 83.43.18.196:62249] PHP Notice: Trying to access array offset on value of type bool in /var/www/html/vault/gpg_auth.php on line 122
[Sun Dec 31 15:54:42.587471 2023] [php7:error] [pid 28228] [client 83.43.18.196:62249] PHP Fatal error: Uncaught Exception: get_key failed in /var/www/html/vault/gpg_auth.php:122\nStack trace:\n#0 /var/www/html/vault/gpg_auth.php(122): gnupg->addencryptkey()\n#1 /var/www/html/vault/gpg_auth.php(228): GpgAuth->stage0()\n#2 /var/www/html/vault/index.php(9): GpgAuth->login()\n#3 {main}\n thrown in /var/www/html/vault/gpg_auth.php on line 122

I think that the notice can be fixed removing the ['info'] key of line 122, but the error is still there.

pd: Is the private key passphrase the same than my user password?

Thanks

@rpo-fr
Copy link

rpo-fr commented Aug 22, 2024

Hello,
I had the same log, after changing the constructor in gpg_auth.php with this line, it works for me
$this->gpg = new \gnupg(['home_dir' => '/tmp/.gnupg']);

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

No branches or pull requests

2 participants