The Basics
- Nextcloud Server version:
31.0.8
- Operating system and version (e.g., Ubuntu 24.04):
Debian 12.11
- Web server and version (e.g, Apache 2.4.25):
Apache 2.4.62
- Reverse proxy and version _(e.g. nginx 1.27.2)
haproxy 3.0.11
- PHP version (e.g, 8.3):
8.3
- Is this the first time you’ve seen this error? (Yes / No):
yes
- When did this problem seem to first start?
after installation of guests plugin
- Installation method (e.g. AlO, NCP, Bare Metal/Archive, etc.)
replace me
- Are you using CloudfIare, mod_security, or similar? (Yes / No)
No
Summary of the issue you are facing:
I can’t login with a guest account over app oder client, only over a browser.
Steps to replicate it (hint: details matter!):
- Go to Nextcloud App or client
- Add Account
- Try to Login with your guest account
- it redirects you back to login window
Log entries
Nextcloud
{"reqId":"bykXACM2BEIB4xqzWeom","level":3,"time":"2025-09-02T15:49:07+00:00","remoteAddr":"46.140.111.66","user":"--","app":"no app in context","method":"GET","url":"/ocs/v2.php/apps/guests/api/v1/groups","message":"Call to a member function getUID() on null in file '/var/www/nextcloud/apps/guests/lib/Controller/APIController.php' line 123","userAgent":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/139.0.0.0 Safari/537.36","version":"31.0.8.1","exception":{"Exception":"Exception","Message":"Call to a member function getUID() on null in file '/var/www/nextcloud/apps/guests/lib/Controller/APIController.php' line 123","Code":0,"Trace":[{"file":"/var/www/nextcloud/lib/private/AppFramework/App.php","line":161,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/Route/Router.php","line":315,"function":"main","class":"OC\\AppFramework\\App","type":"::"},{"file":"/var/www/nextcloud/ocs/v1.php","line":49,"function":"match","class":"OC\\Route\\Router","type":"->"},{"file":"/var/www/nextcloud/ocs/v2.php","line":7,"args":["/var/www/nextcloud/ocs/v1.php"],"function":"require_once"}],"File":"/var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","Line":146,"Previous":{"Exception":"Error","Message":"Call to a member function getUID() on null","Code":0,"Trace":[{"file":"/var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":200,"function":"groups","class":"OCA\\Guests\\Controller\\APIController","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/Http/Dispatcher.php","line":114,"function":"executeController","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/AppFramework/App.php","line":161,"function":"dispatch","class":"OC\\AppFramework\\Http\\Dispatcher","type":"->"},{"file":"/var/www/nextcloud/lib/private/Route/Router.php","line":315,"function":"main","class":"OC\\AppFramework\\App","type":"::"},{"file":"/var/www/nextcloud/ocs/v1.php","line":49,"function":"match","class":"OC\\Route\\Router","type":"->"},{"file":"/var/www/nextcloud/ocs/v2.php","line":7,"args":["/var/www/nextcloud/ocs/v1.php"],"function":"require_once"}],"File":"/var/www/nextcloud/apps/guests/lib/Controller/APIController.php","Line":123},"message":"Call to a member function getUID() on null in file '/var/www/nextcloud/apps/guests/lib/Controller/APIController.php' line 123","exception":[],"CustomMessage":"Call to a member function getUID() on null in file '/var/www/nextcloud/apps/guests/lib/Controller/APIController.php' line 123"},"id":"68b7141c876c2"}
Configuration
Nextcloud
{
"system": {
"instanceid": "***REMOVED SENSITIVE VALUE***",
"passwordsalt": "***REMOVED SENSITIVE VALUE***",
"secret": "***REMOVED SENSITIVE VALUE***",
"trusted_domains": [
"nextcloud.test.test.ch"
],
"datadirectory": "***REMOVED SENSITIVE VALUE***",
"dbtype": "mysql",
"version": "31.0.8.1",
"overwrite.cli.url": "https:\/\/nextcloud.test.test.ch",
"overwriteprotocol": "https",
"dbname": "***REMOVED SENSITIVE VALUE***",
"dbhost": "***REMOVED SENSITIVE VALUE***",
"dbport": "",
"dbtableprefix": "oc_",
"mysql.utf8mb4": true,
"dbuser": "***REMOVED SENSITIVE VALUE***",
"dbpassword": "***REMOVED SENSITIVE VALUE***",
"installed": true,
"memcache.local": "\\OC\\Memcache\\APCu",
"skeletondirectory": "",
"ldapIgnoreNamingRules": false,
"mail_smtpmode": "smtp",
"mail_sendmailmode": "smtp",
"mail_from_address": "***REMOVED SENSITIVE VALUE***",
"mail_domain": "***REMOVED SENSITIVE VALUE***",
"mail_smtphost": "***REMOVED SENSITIVE VALUE***",
"mail_smtpport": "587",
"mail_smtpauth": 1,
"mail_smtpname": "***REMOVED SENSITIVE VALUE***",
"mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
"maintenance": false,
"maintenance_window_start": 23,
"theme": "",
"default_phone_region": "CH",
"loglevel": 2,
"log_type": "file",
"logfile": "\/var\/log\/nextcloud\/nextcloud.log",
"log_rotate_size": "5000000",
"filesystem_check_changes": 1,
"trashbin_retention_obligation": "auto",
"updater.release.channel": "stable",
"ldapProviderFactory": "OCA\\User_LDAP\\LDAPProviderFactory",
"forbidden_filename_characters": [
"\\",
"\/"
],
"forbidden_filename_extensions": [
".filepart",
".part"
],
"twofactor_enforced": "false",
"twofactor_enforced_groups": [],
"twofactor_enforced_excluded_groups": []
},
"apps": {
"activity": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": "filesystem"
},
"app_api": {
"enabled": "yes",
"installed_version": "5.0.2",
"types": ""
},
"backgroundjob": {
"lastjob": "1"
},
"bruteForce": {
"whitelist_1": "10.10.4.0\/24"
},
"bruteforcesettings": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": ""
},
"circles": {
"enabled": "yes",
"installed_version": "31.0.0",
"loopback_tmp_scheme": "https",
"maintenance_run": "0",
"maintenance_update": "{\"maximum\":3,\"3\":1756836002,\"2\":1756839601,\"1\":1756839601,\"4\":1661047201,\"5\":1660964402}",
"migration_22": "1",
"migration_22_1": "1",
"migration_run": "0",
"types": "filesystem,dav"
},
"cloud_federation_api": {
"enabled": "yes",
"installed_version": "1.14.0",
"types": "filesystem"
},
"comments": {
"enabled": "yes",
"installed_version": "1.21.0",
"types": "logging"
},
"contactsinteraction": {
"enabled": "yes",
"installed_version": "1.12.0",
"types": "dav"
},
"core": {
"backgroundjobs_mode": "cron",
"emailTestSuccessful": "1",
"files_metadata_installed": "1",
"installed.bundles": "[\"CoreBundle\"]",
"installedat": "1648215001.5955",
"lastcron": 1756839601,
"lastupdateResult": "[]",
"lastupdatedat": 1756837895,
"metadataGenerationDone": "true",
"moveavatarsdone": "yes",
"previewsCleanedUp": "1",
"public_files": "files_sharing\/public.php",
"public_webdav": "dav\/appinfo\/v1\/publicwebdav.php",
"shareapi_allow_links": "yes",
"shareapi_allow_resharing": "yes",
"shareapi_default_expire_date": "yes",
"shareapi_enable_link_password_by_default": "no",
"shareapi_enforce_expire_date": "no",
"shareapi_enforce_links_password": "yes",
"shareapi_expire_after_n_days": "70",
"shareapi_only_share_with_group_members": "no",
"theming.variables": "b4b8f16018e8ded0c816875118ce51a6",
"updater.secret.created": 1756813842,
"vendor": "nextcloud",
"files_metadata": {
"photos-original_date_time": {
"value": null,
"type": "int",
"etag": "",
"indexed": true,
"editPermission": 0
},
"photos-exif": {
"value": null,
"type": "array",
"etag": "",
"indexed": false,
"editPermission": 0
},
"photos-ifd0": {
"value": null,
"type": "array",
"etag": "",
"indexed": false,
"editPermission": 0
},
"photos-gps": {
"value": null,
"type": "array",
"etag": "",
"indexed": false,
"editPermission": 0
},
"photos-size": {
"value": null,
"type": "array",
"etag": "",
"indexed": false,
"editPermission": 0
},
"photos-place": {
"value": null,
"type": "string",
"etag": "",
"indexed": true,
"editPermission": 0
},
"blurhash": {
"value": null,
"type": "string",
"etag": "68b69ca1b5e67",
"indexed": false,
"editPermission": 0
}
},
"oc.integritycheck.checker": []
},
"dashboard": {
"enabled": "yes",
"installed_version": "7.11.0",
"types": ""
},
"dav": {
"buildCalendarReminderIndex": "yes",
"buildCalendarSearchIndex": "yes",
"builtSocialSearchIndex": "yes",
"chunks_migrated": "1",
"enabled": "yes",
"installed_version": "1.33.0",
"needs_system_address_book_sync": "no",
"regeneratedBirthdayCalendarsForYearFix": "yes",
"types": "filesystem"
},
"federatedfilesharing": {
"enabled": "yes",
"installed_version": "1.21.0",
"types": ""
},
"federation": {
"enabled": "yes",
"installed_version": "1.21.0",
"types": "authentication"
},
"files": {
"default_quota": "1 GB",
"enabled": "yes",
"installed_version": "2.3.1",
"mimetype_version": "31.0.8.1",
"types": "filesystem"
},
"files_downloadlimit": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": ""
},
"files_external": {
"allow_user_mounting": "yes",
"enabled": "yes",
"installed_version": "1.23.0",
"types": "filesystem",
"user_mounting_backends": "smb,\\OC\\Files\\Storage\\SMB_OC"
},
"files_pdfviewer": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": ""
},
"files_reminders": {
"enabled": "yes",
"installed_version": "1.4.0",
"types": ""
},
"files_rightclick": {
"enabled": "no",
"installed_version": "1.6.0",
"types": ""
},
"files_sharing": {
"enabled": "yes",
"installed_version": "1.23.1",
"types": "filesystem"
},
"files_trashbin": {
"enabled": "yes",
"installed_version": "1.21.0",
"types": "filesystem,dav"
},
"files_versions": {
"enabled": "yes",
"installed_version": "1.24.0",
"types": "filesystem,dav"
},
"firstrunwizard": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": ""
},
"guests": {
"allow_external_storage": true,
"create_restricted_to_group": [],
"enabled": "yes",
"hide_users": false,
"installed_version": "4.5.0",
"types": "authentication",
"usewhitelist": false,
"whitelist": "files_trashbin,files_versions,text,activity,notifications,viewer,files_external,files_pdfviewer,files_sharing,firstrunwizard,photos"
},
"logreader": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": "logging"
},
"lookup_server_connector": {
"enabled": "yes",
"installed_version": "1.19.0",
"types": "authentication"
},
"nextcloud_announcements": {
"enabled": "yes",
"installed_version": "3.0.0",
"pub_date": "Thu, 24 Oct 2019 00:00:00 +0200",
"types": "logging"
},
"notifications": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": "logging"
},
"oauth2": {
"enabled": "yes",
"installed_version": "1.19.1",
"types": "authentication"
},
"password_policy": {
"enabled": "yes",
"installed_version": "3.0.0",
"types": "authentication"
},
"photos": {
"enabled": "yes",
"installed_version": "4.0.0",
"lastPlaceMappedUser": "FB4954D0-69EC-4189-AA1F-A6461A5CE8F0",
"lastPlaceMappingDone": "true",
"types": "dav,authentication"
},
"privacy": {
"enabled": "yes",
"installed_version": "3.0.0",
"types": ""
},
"profile": {
"enabled": "yes",
"installed_version": "1.0.0",
"types": ""
},
"provisioning_api": {
"enabled": "yes",
"installed_version": "1.21.0",
"types": "prevent_group_restriction"
},
"recommendations": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": ""
},
"related_resources": {
"enabled": "yes",
"installed_version": "2.0.0",
"types": ""
},
"serverinfo": {
"cached_count_appdata_files": 50879,
"cached_count_filecache": 4558573,
"cached_count_storages": "459",
"enabled": "yes",
"installed_version": "3.0.0",
"size_appdata_storage": 59922994,
"types": ""
},
"settings": {
"enabled": "yes",
"installed_version": "1.14.0",
"types": ""
},
"sharebymail": {
"enabled": "yes",
"installed_version": "1.21.0",
"types": "filesystem"
},
"sharereview": {
"enabled": "no",
"installed_version": "1.4.0",
"types": ""
},
"support": {
"SwitchUpdaterServerHasRun": "yes",
"enabled": "yes",
"installed_version": "3.0.0",
"types": "session"
},
"survey_client": {
"enabled": "yes",
"installed_version": "3.0.0",
"types": ""
},
"systemtags": {
"enabled": "yes",
"installed_version": "1.21.1",
"types": "logging"
},
"text": {
"enabled": "yes",
"installed_version": "5.0.0",
"types": "dav"
},
"theming": {
"backgroundMime": "backgroundColor",
"background_color": "#222222",
"cachebuster": "13",
"enabled": "yes",
"installed_version": "2.6.1",
"logoDimensions": "258x37",
"logoMime": "image\/svg+xml",
"name": "Test",
"primary_color": "#222222",
"slogan": "***REMOVED SENSITIVE VALUE***",
"types": "logging",
"url": "***REMOVED SENSITIVE VALUE***"
},
"twofactor_backupcodes": {
"enabled": "yes",
"installed_version": "1.20.0",
"types": ""
},
"updatenotification": {
"bruteforcesettings": "2.4.0",
"core": "30.0.14.1",
"enabled": "yes",
"installed_version": "1.21.0",
"types": "",
"update_check_errors": 0
},
"user_ldap": {
"background_sync_interval": "43200",
"background_sync_offset": "0",
"background_sync_prefix": "s01",
"cleanUpJobOffset": "0",
"enabled": "yes",
"installed_version": "1.22.0",
"s01_lastChange": "1756838361",
"s01has_memberof_filter_support": "1",
"s01home_folder_naming_rule": "",
"s01last_jpegPhoto_lookup": "0",
"s01ldap_agent_password": "***REMOVED SENSITIVE VALUE***",
"s01ldap_attributes_for_group_search": "",
"s01ldap_attributes_for_user_search": "",
"s01ldap_backup_host": "",
"s01ldap_backup_port": "7389",
"s01ldap_base": "dc=test,dc=lan",
"s01ldap_base_groups": "dc=test,dc=lan",
"s01ldap_base_users": "dc=test,dc=lan",
"s01ldap_cache_ttl": "600",
"s01ldap_configuration_active": "1",
"s01ldap_default_ppolicy_dn": "",
"s01ldap_display_name": "displayname",
"s01ldap_dn": "uid=joinuser,cn=users,dc=test,dc=lan",
"s01ldap_dynamic_group_member_url": "",
"s01ldap_email_attr": "mail",
"s01ldap_experienced_admin": "0",
"s01ldap_expert_username_attr": "",
"s01ldap_expert_uuid_group_attr": "",
"s01ldap_expert_uuid_user_attr": "",
"s01ldap_ext_storage_home_attribute": "",
"s01ldap_gid_number": "gidNumber",
"s01ldap_group_display_name": "cn",
"s01ldap_group_filter": "(|(cn=geschaeftsleitung)(cn=projektleitung)(cn=teamleitung)(cn=ausbildung)(cn=administration-office))",
"s01ldap_group_filter_mode": "1",
"s01ldap_group_member_assoc_attribute": "gidNumber",
"s01ldap_groupfilter_groups": "geschaeftsleitung\nprojektleitung\nteamleitung\nausbildung\nadministration-office",
"s01ldap_groupfilter_objectclass": "",
"s01ldap_host": "test.lan",
"s01ldap_login_filter": "(&(&(|(objectclass=person))(|(memberof=cn=nextcloud,cn=groups,dc=test,dc=lan)))(uid=%uid))",
"s01ldap_login_filter_mode": "1",
"s01ldap_loginfilter_attributes": "",
"s01ldap_loginfilter_email": "0",
"s01ldap_loginfilter_username": "1",
"s01ldap_matching_rule_in_chain_state": "unknown",
"s01ldap_nested_groups": "0",
"s01ldap_override_main_server": "",
"s01ldap_paging_size": "500",
"s01ldap_port": "7389",
"s01ldap_quota_attr": "",
"s01ldap_quota_def": "",
"s01ldap_tls": "0",
"s01ldap_turn_off_cert_check": "0",
"s01ldap_turn_on_pwd_change": "0",
"s01ldap_user_avatar_rule": "default",
"s01ldap_user_display_name_2": "",
"s01ldap_user_filter_mode": "0",
"s01ldap_userfilter_groups": "nextcloud",
"s01ldap_userfilter_objectclass": "person",
"s01ldap_userlist_filter": "(&(|(objectclass=person))(|(memberof=cn=nextcloud,cn=groups,dc=test,dc=lan)))",
"s01use_memberof_to_detect_membership": "1",
"types": "authentication"
},
"user_status": {
"enabled": "yes",
"installed_version": "1.11.0",
"types": ""
},
"viewer": {
"enabled": "yes",
"installed_version": "4.0.0",
"types": ""
},
"weather_status": {
"enabled": "yes",
"installed_version": "1.11.0",
"types": ""
},
"webhook_listeners": {
"enabled": "yes",
"installed_version": "1.2.0",
"types": "filesystem"
},
"workflowengine": {
"enabled": "yes",
"installed_version": "2.13.0",
"types": "filesystem"
}
}
}
Apps
The output of occ app:list
(if possible).
Enabled:
- activity: 4.0.0
- app_api: 5.0.2
- bruteforcesettings: 4.0.0
- circles: 31.0.0
- cloud_federation_api: 1.14.0
- comments: 1.21.0
- contactsinteraction: 1.12.0
- dashboard: 7.11.0
- dav: 1.33.0
- federatedfilesharing: 1.21.0
- federation: 1.21.0
- files: 2.3.1
- files_downloadlimit: 4.0.0
- files_external: 1.23.0
- files_pdfviewer: 4.0.0
- files_reminders: 1.4.0
- files_sharing: 1.23.1
- files_trashbin: 1.21.0
- files_versions: 1.24.0
- firstrunwizard: 4.0.0
- guests: 4.5.0
- logreader: 4.0.0
- lookup_server_connector: 1.19.0
- nextcloud_announcements: 3.0.0
- notifications: 4.0.0
- oauth2: 1.19.1
- password_policy: 3.0.0
- photos: 4.0.0
- privacy: 3.0.0
- profile: 1.0.0
- provisioning_api: 1.21.0
- recommendations: 4.0.0
- related_resources: 2.0.0
- serverinfo: 3.0.0
- settings: 1.14.0
- sharebymail: 1.21.0
- support: 3.0.0
- survey_client: 3.0.0
- systemtags: 1.21.1
- text: 5.0.0
- theming: 2.6.1
- twofactor_backupcodes: 1.20.0
- updatenotification: 1.21.0
- user_ldap: 1.22.0
- user_status: 1.11.0
- viewer: 4.0.0
- weather_status: 1.11.0
- webhook_listeners: 1.2.0
- workflowengine: 2.13.0