Repository: nilsteampassnet/TeamPass

Issue #2027: Fatal Error after installation 
Created: 2017-11-22T16:43:19Z
Steps to reproduce

Install TeamPass normally
navigate to localhost/teampass
Error is given

Expected behaviour
Teampass should start normally
Actual behaviour
I get the following error:
Fatal error: Uncaught Error: Call to undefined function defuse_return_decrypted() in /var/www/html/teampass/index.php:78 Stack trace: #0 {main} thrown in /var/www/html/teampass/index.php on line 78
Server configuration
Operating system: Ubuntu Server 16.04
Web server:
Apache2
Database:
MySQL
PHP version:
7.0.22
Teampass version:
I'm not entirely certain, I assume the newest one.
Teampass configuration file:
Updated from an older Teampass or fresh install: Fresh
PLEASE attach to this message the file /includes/config/tp.config.php.
 '10',
    'enable_favourites' => '1',
    'show_last_items' => '1',
    'enable_pf_feature' => '0',
    'log_connections' => '0',
    'log_accessed' => '1',
    'time_format' => 'H:i:s',
    'date_format' => 'd/m/Y',
    'duplicate_folder' => '0',
    'item_duplicate_in_same_folder' => '0',
    'duplicate_item' => '0',
    'number_of_used_pw' => '3',
    'manager_edit' => '1',
    'cpassman_dir' => '/var/www/html/teampass',
    'cpassman_url' => 'http://picard/teampass',
    'favicon' => 'http://picard/teampass/favicon.ico',
    'path_to_upload_folder' => '/var/www/html/teampass/upload',
    'url_to_upload_folder' => 'http://picard/teampass/upload',
    'path_to_files_folder' => '/var/www/html/teampass/files',
    'url_to_files_folder' => 'http://picard/teampass/files',
    'activate_expiration' => '0',
    'pw_life_duration' => '0',
    'maintenance_mode' => '1',
    'enable_sts' => '0',
    'encryptClientServer' => '1',
    'cpassman_version' => '2.1.27',
    'ldap_mode' => '0',
    'ldap_type' => '0',
    'ldap_suffix' => '0',
    'ldap_domain_dn' => '0',
    'ldap_domain_controler' => '0',
    'ldap_user_attribute' => '0',
    'ldap_ssl' => '0',
    'ldap_tls' => '0',
    'ldap_elusers' => '0',
    'ldap_search_base' => '0',
    'richtext' => '0',
    'allow_print' => '0',
    'roles_allowed_to_print' => '0',
    'show_description' => '1',
    'anyone_can_modify' => '0',
    'anyone_can_modify_bydefault' => '0',
    'nb_bad_authentication' => '0',
    'utf8_enabled' => '1',
    'restricted_to' => '0',
    'restricted_to_roles' => '0',
    'enable_send_email_on_user_login' => '0',
    'enable_user_can_create_folders' => '0',
    'insert_manual_entry_item_history' => '0',
    'enable_kb' => '0',
    'enable_email_notification_on_item_shown' => '0',
    'enable_email_notification_on_user_pw_change' => '0',
    'custom_logo' => '',
    'custom_login_text' => '',
    'default_language' => 'english',
    'send_stats' => '0',
    'send_statistics_items' => 'stat_country;stat_users;stat_items;stat_items_shared;stat_folders;stat_folders_shared;stat_admins;stat_managers;stat_ro;stat_mysqlversion;stat_phpversion;stat_teampassversion;stat_languages;stat_kb;stat_suggestion;stat_customfields;stat_api;stat_2fa;stat_agses;stat_duo;stat_ldap;stat_syslog;stat_stricthttps;stat_fav;stat_pf;',
    'send_stats_time' => '1508774952',
    'get_tp_info' => '1',
    'send_mail_on_user_login' => '0',
    'sending_emails' => '0',
    'nb_items_by_query' => 'auto',
    'enable_delete_after_consultation' => '0',
    'enable_personal_saltkey_cookie' => '0',
    'personal_saltkey_cookie_duration' => '31',
    'email_smtp_server' => '',
    'email_smtp_auth' => '',
    'email_auth_username' => '',
    'email_auth_pwd' => '',
    'email_port' => '',
    'email_security' => '',
    'email_server_url' => '',
    'email_from' => '',
    'email_from_name' => '',
    'pwd_maximum_length' => '40',
    'google_authentication' => '0',
    'delay_item_edition' => '0',
    'allow_import' => '0',
    'proxy_ip' => '',
    'proxy_port' => '',
    'upload_maxfilesize' => '10mb',
    'upload_docext' => 'doc,docx,dotx,xls,xlsx,xltx,rtf,csv,txt,pdf,ppt,pptx,pot,dotx,xltx',
    'upload_imagesext' => 'jpg,jpeg,gif,png',
    'upload_pkgext' => '7z,rar,tar,zip',
    'upload_otherext' => 'sql,xml',
    'upload_imageresize_options' => '1',
    'upload_imageresize_width' => '800',
    'upload_imageresize_height' => '600',
    'upload_imageresize_quality' => '90',
    'use_md5_password_as_salt' => '0',
    'ga_website_name' => 'TeamPass for ChangeMe',
    'api' => '0',
    'subfolder_rights_as_parent' => '0',
    'show_only_accessible_folders' => '0',
    'enable_suggestion' => '0',
    'otv_expiration_period' => '7',
    'default_session_expiration_time' => '60',
    'duo' => '0',
    'enable_server_password_change' => '0',
    'ldap_object_class' => '0',
    'bck_script_path' => '/var/www/html/teampass/backups',
    'bck_script_filename' => 'bck_teampass',
    'syslog_enable' => '0',
    'syslog_host' => 'localhost',
    'syslog_port' => '514',
    'manager_move_item' => '0',
    'create_item_without_password' => '0',
    'otv_is_enabled' => '0',
    'agses_authentication_enabled' => '0',
    'item_extra_fields' => '0',
    'saltkey_ante_2127' => 'none',
    'migration_to_2127' => 'done',
    'files_with_defuse' => 'done',
    'timezone' => 'UTC',
    'enable_attachment_encryption' => '1',
    'personal_saltkey_security_level' => '50',
    'ldap_new_user_is_administrated_by' => '0'

### Client configuration
**Browser:** Chrome

**Operating system:** Windows 10 Enterprise

### Logs
#### Web server error log
```
Insert your webserver log here
```

#### Log from the web-browser developer console (CTRL + SHIFT + i)
```
Insert the log here and especially the answer of the query that failed.
```

Duplicate issue #2023: Blank page after enabling LDAP
Created: 2017-11-17T20:04:31Z
Steps to reproduce

Fresh install: Ubuntu 16.04, LEMP
Initial config then Manage Settings>Options>LDAP>
Enable LDAP.  Enter configs, click-away.
3b.  May have something to do with clicking into Administrator's profile, As i have done this at several places and it corrupts the current logged-in session.

    'ldap_new_user_is_administrated_by' => '0' is created without a trailing comma (,)
Expected behaviour
website working
Actual behaviour
website was a blank page. (empty iframe)
Resolution / Fix
Manually edit includes/config/tp.config.php to include comma behind ldap_new_user_is_administrated_by
Server configuration
Operating system:
Ubuntu 16.04.3 LTS
Linux teampass 4.4.0-98-generic #121-Ubuntu SMP Tue Oct 10 14:24:03 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Web server:
nginx version: nginx/1.10.3 (Ubuntu)
Database:
mariadb-server 10.0.31-MariaDB-0ubuntu0.16.04.2
PHP version:
PHP 7.0.22-0ubuntu0.16.04.1
Teampass version:
Release 2.1.27.10
Teampass configuration file:
Fresh install:
PLEASE attach to this message the file /includes/config/tp.config.php.
tp.config.php.txt
Client configuration
Browser:
Firefox 64bit 56.0.2
Operating system:
Debian 9
Logs
Web server error log
/var/log/nginx/error.log
2017/11/17 13:50:45 [error] 1197#1197: *161 FastCGI sent in stderr: "PHP message: PHP Parse error:  syntax error, unexpected ''copy_to_clipboard_small_icons' (T_CONSTANT_ENCAPSED_STRING), expecting ')' in /var/www/html/teampass/includes/config/tp.config.php on line 121" while reading response header from upstream, client: 10.50.5.47, server: teampass.DOMAIN.TLD, request: "GET /index.php?page=manage_settings&language= HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.0-fpm.sock:", host: "teampass.DOMAIN.TLD", referrer: "https://teampass.DOMAIN.TLD/index.php?page=manage_settings"

Closing comment (2017-11-23T12:00:10Z): Duplicate of #2027
I think I found the reason and will commit a fix.