Internal Error on password or user creation

Hi All,

I have just installed passbolt on my test box, I have created the first user and are able to login into the system. How ever, whenever I try to create an user o password, I get and error saying: “Error: An Internal Error Has Occurred.”

Here is my system information:
– Server operating system name and version: Debian 10
– Web server name and version: nginx/1.14.2
– Database server name and version: MariaDB 10.3.22-MariaDB-0+deb10u1
– Php version: PHP 7.3.14-1~deb10u1 (built: Feb 16 2020 15:07:23) ( NTS )
– Passbolt version: 2.12.0

Here is my healthcheck:

 Environment

 [PASS] PHP version 7.3.14-1~deb10u1.
 [PASS] PCRE compiled with unicode support.
 [PASS] The temporary directory and its content are writable.
 [PASS] The public image directory and its content are writable.
 [PASS] The logs directory and its content are writable.
 [PASS] GD or Imagick extension is installed.
 [PASS] Intl extension is installed.
 [PASS] Mbstring extension is installed.

 Config files

 [PASS] The application config file is present
 [PASS] The passbolt config file is present

 Core config

 [PASS] Debug mode is off.
 [PASS] Cache is working.
 [PASS] Unique value set for security.salt
 [PASS] Full base url is set to **************
 [PASS] App.fullBaseUrl validation OK.
 [PASS] /healthcheck/status is reachable.

 SSL Certificate

 [PASS] SSL peer certificate validates
 [PASS] Hostname is matching in SSL certificate.
 [PASS] Not using a self-signed certificate

 Database

 [PASS] The application is able to connect to the database
 [PASS] 23 tables found
 [PASS] Some default content is present
 [PASS] The database schema up to date.

 GPG Configuration

 [PASS] PHP GPG Module is installed and loaded.
 [PASS] The environment variable GNUPGHOME is set to /home/www-data/.gnupg.
 [PASS] The directory /home/www-data/.gnupg containing the keyring is writable by the webserver user.
 [PASS] The server gpg key is not the default one
 [PASS] The public key file is defined in config/passbolt.php and readable.
 [PASS] The private key file is defined in config/passbolt.php and readable.
 [PASS] The server key fingerprint matches the one defined in config/passbolt.php.
 [PASS] The server public key defined in the config/passbolt.php (or environment variables) is in the keyring.
 [PASS] There is a valid email id defined for the server key.
 [PASS] The public key can be used to encrypt a message.
 [PASS] The private key can be used to sign a message.
 [PASS] The public and private keys can be used to encrypt and sign a message.
 [PASS] The private key can be used to decrypt a message.
 [PASS] The private key can be used to decrypt and verify a message.
 [PASS] The public key can be used to verify a signature.

 Application configuration

 [PASS] Using latest passbolt version (2.12.0).
 [PASS] Passbolt is configured to force SSL use.
 [PASS] App.fullBaseUrl is set to HTTPS.
 [PASS] Selenium API endpoints are disabled.
 [PASS] Search engine robots are told not to index content.
 [PASS] Registration is closed, only administrators can add users.
 [PASS] Serving the compiled version of the javascript app
 [PASS] All email notifications will be sent.

No error found. Nice one sparky!

here are the error logs I have:

2020-03-02 17:54:27 Error: [PDOException] SQLSTATE[HY000]: General error: 1364 Field 'email' doesn't have a default value (/var/www/passbolt/vendor/cakephp/cakephp/src/Database/Statement/MysqlStatement.php:38)
Request URL: /users/recover
Referer URL: https://**********/users/recover

2020-03-02 17:57:04 Error: [PDOException] SQLSTATE[HY000]: General error: 1364 Field 'email' doesn't have a default value (/var/www/passbolt/vendor/cakephp/cakephp/src/Database/Statement/MysqlStatement.php:38)
Request URL: /users.json?api-version=v2
Referer URL: https://*******/app/users


2020-03-02 18:03:18 Error: [PDOException] SQLSTATE[HY000]: General error: 1364 Field 'email' doesn't have a default value (/var/www/passbolt/vendor/cakephp/cakephp/src/Database/Statement/MysqlStatement.php:38)
Request URL: /users/recover.json?api-version=v2
Referer URL: https://*******/app/users


2020-03-02 18:06:14 Error: [PDOException] SQLSTATE[HY000]: General error: 1364 Field 'email' doesn't have a default value (/var/www/passbolt/vendor/cakephp/cakephp/src/Database/Statement/MysqlStatement.php:38)
Request URL: /resources.json?api-version=v2


2020-03-02 18:36:18 Error: [PDOException] SQLSTATE[HY000]: General error: 1364 Field 'email' doesn't have a default value (/var/www/passbolt/vendor/cakephp/cakephp/src/Database/Statement/MysqlStatement.php:38)
Request URL: /resources.json?api-version=v2

They all seem related to email, but running the send test email (https://help.passbolt.com/faq/hosting/why-email-not-sent) works perfecty

Since I have just installed this server using this guide (https://help.passbolt.com/hosting/install/ce/debian-10-buster.html) Which installed correctly, with the exception of activating the letsencrypt certificate. Here is the relevant part of the install log:

=====================
Setting up mariadb...
=====================
Synchronizing state of php7.3-fpm.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable php7.3-fpm
gpg: WARNING: unsafe permissions on homedir '/home/www-data/.gnupg'
gpg: keybox '/home/www-data/.gnupg/pubring.kbx' created
gpg: /home/www-data/.gnupg/trustdb.gpg: trustdb created
Cloning into '/var/www/passbolt'...
remote: Enumerating objects: 891, done.        
remote: Counting objects:   0% (1/891)        







remote: Compressing objects:   0% (1/716)        








Receiving objects:   0% (1/891)   






Receiving objects: 100% (891/891), 2.99 MiB | 210.00 KiB/s   
Resolving deltas:   0% (0/322)   




======================
Installing composer...
======================
--2020-03-02 10:36:10--  https://getcomposer.org/installer
Resolving getcomposer.org (getcomposer.org)... 142.44.245.229, 2607:5300:201:2100::4:d105
Connecting to getcomposer.org (getcomposer.org)|142.44.245.229|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 277120 (271K) [application/octet-stream]
Saving to: ‘composer-setup.php’

     0K .......... .......... .......... .......... .......... 18%  544K 0s
    50K .......... .......... .......... .......... .......... 36%  553K 0s
   100K .......... .......... .......... .......... .......... 55% 6.65M 0s
   150K .......... .......... .......... .......... .......... 73%  397K 0s
   200K .......... .......... .......... .......... .......... 92% 13.3M 0s
   250K .......... ..........                                 100% 28.3M=0.3s

2020-03-02 10:36:11 (846 KB/s) - ‘composer-setup.php’ saved [277120/277120]

All settings correct for using Composer
Downloading...

Composer (version 1.9.3) successfully installed to: /usr/bin/composer.phar
Use it: php /usr/bin/composer.phar

===================================
Installing composer dependencies...
===================================
Loading composer repositories with package information
Installing dependencies from lock file
Package operations: 34 installs, 0 updates, 0 removals
  - Installing cakephp/plugin-installer (1.1.1): Downloading (100%)         
  - Installing thadafinser/package-info (v1.0.0): Downloading (100%)         
  - Installing aura/intl (3.0.0): Downloading (100%)         
  - Installing knplabs/gaufrette (v0.7.0): Downloading (100%)         
  - Installing symfony/polyfill-ctype (v1.13.1): Downloading (100%)         
  - Installing symfony/yaml (v3.4.36): Downloading (100%)         
  - Installing symfony/polyfill-mbstring (v1.13.1): Downloading (100%)         
  - Installing psr/log (1.1.2): Downloading (100%)         
  - Installing symfony/debug (v3.4.36): Downloading (100%)         
  - Installing symfony/console (v3.4.36): Downloading (75%)          
Downloading (100%)
  - Installing symfony/filesystem (v3.4.36): Downloading (100%)         
  - Installing symfony/config (v3.4.36): Downloading (75%)          
Downloading (100%)
  - Installing psr/http-message (1.0.1): Downloading (100%)         
  - Installing zendframework/zend-diactoros (1.8.7): Downloading (100%)         
  - Installing psr/simple-cache (1.0.1): Downloading (100%)         
  - Installing cakephp/chronos (1.3.0): Downloading (100%)         
  - Installing cakephp/cakephp (3.8.6): Downloading (100%)         
  - Installing robmorgan/phinx (0.11.1): Downloading (100%)         
  - Installing cakephp/migrations (2.4.0): Downloading (100%)         
  - Installing burzum/cakephp-file-storage (2.1): Downloading (100%)         
  - Installing imagine/imagine (v0.6.3): Downloading (75%)          
Downloading (100%)
  - Installing burzum/cakephp-imagine-plugin (3.x-dev 3ef5969): Cloning 3ef5969d1d from cache
  - Installing donatj/phpuseragentparser (v0.7.0): Downloading (100%)         
  - Installing guzzlehttp/promises (v1.3.1): Downloading (100%)         
  - Installing ralouphie/getallheaders (3.0.3): Downloading (100%)         
  - Installing guzzlehttp/psr7 (1.6.1): Downloading (100%)         
  - Installing lorenzo/cakephp-email-queue (3.3.1): Downloading (100%)         
  - Installing mobiledetect/mobiledetectlib (2.8.34): Downloading (100%)         
  - Installing paragonie/random_compat (v9.99.99): Downloading (100%)         
  - Installing ramsey/uuid (3.9.1): Downloading (100%)         
  - Installing phpseclib/phpseclib (2.0.4): Downloading (75%)          
Downloading (100%)
  - Installing singpolyma/openpgp-php (0.3.0): Downloading (100%)         
  - Installing guzzlehttp/guzzle (6.4.1): Downloading (100%)         
  - Installing thadafinser/user-agent-parser (v2.0.0): Downloading (75%)          
Downloading (100%)
Generating optimized autoload files
> Cake\Composer\Installer\PluginInstaller::postAutoloadDump
thadafinser/package-info:  Generating class...
thadafinser/package-info: ...generating class
> App\Console\Installer::postInstall
Created `/var/www/passbolt/logs` directory
Created `/var/www/passbolt/tmp/cache/models` directory
Created `/var/www/passbolt/tmp/cache/persistent` directory
Created `/var/www/passbolt/tmp/cache/views` directory
Created `/var/www/passbolt/tmp/sessions` directory
Created `/var/www/passbolt/tmp/tests` directory
Permissions set on /var/www/passbolt/tmp/cache
Permissions set on /var/www/passbolt/tmp/cache/database
Permissions set on /var/www/passbolt/tmp/cache/models
Permissions set on /var/www/passbolt/tmp/cache/persistent
Permissions set on /var/www/passbolt/tmp/cache/views
Permissions set on /var/www/passbolt/tmp/selenium
Permissions set on /var/www/passbolt/tmp/sessions
Permissions set on /var/www/passbolt/tmp/tests
Permissions set on /var/www/passbolt/tmp
Permissions set on /var/www/passbolt/logs
Updated Security.salt value in config/app.php
===================
Setting up nginx...
===================
Synchronizing state of nginx.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable nginx
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator webroot, Installer None
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for thevaultofglass.cibernetica.net
Using the webroot path /var/www/passbolt/webroot for all unmatched domains.
Waiting for verification...
Cleaning up challenges
Failed authorization procedure. thevaultofglass.cibernetica.net (http-01): urn:ietf:params:acme:error:connection :: The server could not connect to the client to veri
fy the domain :: Fetching http://thevaultofglass.cibernetica.net/.well-known/acme-challenge/7IaCqDu-3xhjrs3nX8v_VkSRekne7It-iOTO8K2_4C4: Timeout during connect (likel
y firewall problem)
IMPORTANT NOTES:
 - The following errors were reported by the server:

   Domain: thevaultofglass.cibernetica.net
   Type:   connection
   Detail: Fetching
   http://thevaultofglass.cibernetica.net/.well-known/acme-challenge/7IaCqDu-3xhjrs3nX8v_VkSRekne7It-iOTO8K2_4C4:
   Timeout during connect (likely firewall problem)

   To fix these errors, please make sure that your domain name was
   entered correctly and the DNS A/AAAA record(s) for that domain
   contain(s) the right IP address. Additionally, please check that
   your computer has a publicly routable IP address and that no
   firewalls are preventing the server from communicating with the
   client. If you're using the webroot plugin, you should also verify
   that you are serving files from the webroot path you provided.
 - Your account credentials have been saved in your Certbot
   configuration directory at /etc/letsencrypt. You should make a
   secure backup of this folder now. This configuration directory will
   also contain certificates and private keys obtained by Certbot so
   making regular backups of this folder is ideal.
=============================================================================
WARNING: Unable to setup SSL using lets encrypt. Please check the install.log
=============================================================================
Ign:1 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 http://dl.google.com/linux/chrome/deb stable Release
Hit:3 https://deb.debian.org/debian stable InRelease
Hit:4 https://deb.debian.org/debian stable-updates InRelease
Hit:6 https://repo.skype.com/deb stable InRelease
Hit:5 http://ds9-eu.s3-website.eu-central-1.amazonaws.com/dci/packages/netrunner netrunner-desktop-2001 InRelease
Hit:8 http://security.debian.org stable/updates InRelease
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
haveged is already the newest version (1.9.1-7).
haveged set to manually installed.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Synchronizing state of haveged.service with SysV service script with /lib/systemd/systemd-sysv-install.
Executing: /lib/systemd/systemd-sysv-install enable haveged
================================================================================
Installation is almost complete. Please point your browser to
  https://thevaultofglass.cibernetica.net to complete the process
================================================================================

STEPS TO TROUBLESHOOT

  1. I have double checked everything in the troubleshooting guides,
  2. I have disabled the email sending cron and created users to see if the email queue is being populated.
  3. I have seen that the email field in email_queue table is not nullable, that might be the cause of the issue…

STEPS TO REPRODUCE

  1. Install passbolt on a debian 10 u1 installation using the scripts
  2. do a manual config of the lets encrypt
  3. setup the solution.
  4. try and create a pasword or another user.

What do you guys think is the problem with the Email sending part?

Best,

Checklist
[X] I have read intro post
[X] I have read the tutorials, help and searched for similar issues
[X] I provide relevant information about my server (component names and versions, etc.)
[X ] I provide a copy of my logs and healthcheck
[X] I describe the steps I have taken to trouble shoot the problem
[X] I describe the steps on how to reproduce the issue

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.