Multi-value attributes (mail/groups) not handled correctly if using environment
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 3/5
- Thời gian dự kiến
- 1-2 ngày
- Mức phù hợp với người mới
- 45/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- apache, php
- Lĩnh vực
- authentication
Hướng nghiên cứu
Bắt đầu trong apps/user_saml/lib/UserBackend.php tại các hàm getAttribute* và lần theo đường đi của biến môi trường đối với các thuộc tính mail và groups được ánh xạ. Xác nhận cách các thuộc tính trực tiếp của IdP được xử lý, sau đó làm cho đường đi của biến môi trường phân tách nhất quán các giá trị được phân cách bằng dấu chấm phẩy và xác minh rằng các thuộc tính nhiều giá trị được lưu riêng biệt mà không làm hỏng các ánh xạ hiện có.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Steps to reproduce
- Configure user_saml with 'Use Environment variable'
- Configure an attribute mapping for mail and groups
- Log into your instance. If you have multiple groups and/or mail addresses, you can see in your personal information that they are not split into multiple values but treated as single values. This may even cause a crash if you are in many groups, because the database column is limited to 64 chars.
Expected behaviour
Multi-value attributes (delimited by semicolons) should be split. It works if not using the environment mechanism but connecting directly to an idp, but I want to integrate nextcloud into a federation, which requires the use of apache/mod_shib/shibd and environment variables.
Actual behaviour
Multi-value attributes are not split but treated as a single value, causing various problems.
I tracked that down to the behaviour of the getAttribute* functions in apps/user_saml/lib/UserBackend.php and I may be able to develop a workaround or clean fix, but of course this problem should be fixed in the official sources.
This bug makes the integration of Nextcloud into a Shibboleth-based federation impossible in many situations.
Server configuration
Operating system:
Ubuntu 22.04
Web server:
Apache 2.4.52
Database:
Postgresql 14
PHP version:
8.1
Nextcloud version: (see Nextcloud admin page)
25.0.3
Where did you install Nextcloud from:
?
List of activated apps:
- activity: 2.17.0
- admin_audit: 1.15.0
- bruteforcesettings: 2.5.0
- calendar: 4.2.3
- circles: 25.0.0
- cloud_federation_api: 1.8.0
- comments: 1.15.0
- contacts: 5.1.0
- contactsinteraction: 1.6.0
- dav: 1.24.0
- deck: 1.8.3
- federatedfilesharing: 1.15.0
- federation: 1.15.0
- files: 1.20.1
- files_pdfviewer: 2.6.0
- files_rightclick: 1.4.0
- files_sharing: 1.17.0
- files_trashbin: 1.15.0
- files_versions: 1.18.0
- issuetemplate: 0.7.0
- logreader: 2.10.0
- lookup_server_connector: 1.13.0
- notes: 4.6.0
- notifications: 2.13.1
- oauth2: 1.13.0
- password_policy: 1.15.0
- photos: 2.0.1
- privacy: 1.9.0
- provisioning_api: 1.15.0
- related_resources: 1.0.3
- serverinfo: 1.15.0
- settings: 1.7.0
- sharebymail: 1.15.0
- systemtags: 1.15.0
- tasks: 0.14.5
- text: 3.6.0
- theming: 2.0.1
- theming_customcss: 1.12.0
- twofactor_backupcodes: 1.14.0
- twofactor_totp: 7.0.0
- updatenotification: 1.15.0
- user_saml: 5.1.2
- user_status: 1.5.0
- viewer: 1.9.0
- weather_status: 1.5.0
- workflowengine: 2.7.0
Nextcloud configuration:
{
"system": {
"debug": true,
"instanceid": "REMOVED SENSITIVE VALUE",
"passwordsalt": "REMOVED SENSITIVE VALUE",
"secret": "REMOVED SENSITIVE VALUE",
"trusted_domains": [
"nc.uni-bremen.de",
"nextcloud.zfn.uni-bremen.de",
"nextcloud.uni-bremen.de",
"nextcloud.vm.uni-bremen.de"
],
"datadirectory": "REMOVED SENSITIVE VALUE",
"dbtype": "pgsql",
"version": "25.0.3.2",
"overwrite.cli.url": "https://nc.uni-bremen.de",
"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",
"default_phone_region": "DE",
"filelocking.enabled": true,
"memcache.locking": "\OC\Memcache\Redis",
"memcache.distributed": "\OC\Memcache\Redis",
"redis": {
"host": "REMOVED SENSITIVE VALUE",
"port": 6379,
"timeout": 0,
"password": "REMOVED SENSITIVE VALUE"
},
"mail_smtpmode": "smtp",
"mail_smtpsecure": "tls",
"mail_sendmailmode": "smtp",
"mail_from_address": "REMOVED SENSITIVE VALUE",
"mail_domain": "REMOVED SENSITIVE VALUE",
"mail_smtphost": "REMOVED SENSITIVE VALUE",
"default_language": "de",
"default_locale": "de_DE",
"lookup_server": "",
"allow_user_to_change_display_name": false,
"enable_previews": true,
"maintenance": false,
"theme": "",
"loglevel": 1,
"trashbin_retention_obligation": "auto,30",
"bulkupload.enabled": false,
"app_install_overwrite": [
"issuetemplate"
]
}
}
Client configuration
Browser:
Firefox, Chrome, Chromium, ...
Operating system:
Ubuntu
- Ngôn ngữ chính
- PHP
- Star
- 106
- Fork
- 84
- Merge trung bình
- 1 ngày 11 giờ
- Pull request đã merge (30 ngày)
- 14
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của nextcloud/user_saml
-
Logout link is empty in environment-variable mode without login form (regression from #1235)Đang mở0. Needs triage bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 80/100
Maintainer thường phản hồi trong vòng 1 ngày
-
0. Needs triage bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 88/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
Maintainer thường phản hồi trong vòng 1 ngày
-
0. Needs triage bug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 57/100
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của nextcloud/user_saml
Issue tương tự
-
Captured slideshow pass overwrites the route path, aborting compose with a rebind() TypeErrorĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
Automattic/blocks-engine#5003 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
from-cloud mythic tracked
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 86/100
MythicalLTD/FeatherPanel#459 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
[Bug]: PostgreSQL backend: Queue.remove() / Job.remove() never emit the QueueEvents "removed" eventCó thể đã có người làm @1AbdullahButt đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
taskforcesh/bullmq#5085 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
shukiv/jabali-panel#2423 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 67/100