Note: This issue might also apply to deck titles, and could as well be a general… problem of nextcloud. I have not checked it yet, but I guess it will show, if the problem lies deeper in some common API
### Steps to reproduce
Create a card with a title "αβγδεζηθικλμνξοπρστυφχψωαβγδεζηθι" (That is 34 greek characters)
try to link this card to anything, a deck, a card, a file, or a conversation. It will fail.
For reference, if you remove the last character, making the length 33, linking to the other objects works as expected.
Note:
It looks like there might be an encoding issue here, as for example url encoded characters like these, would eat up 99 characters in the case of a 33 character string of non-latin characters and 102 in the case of 34 non-latin characters. This might be a combination of problems - the first being the characters being counted wrong due to encoding issues, and the second being an imposed limit of 100 characters, which, i think, was the hard limit for titles in the past.
### Expected behaviour
Link should complete
### Actual behaviour
Link fails responding with "Failed to create a project" in the UI. See browser log below for related network info.
## Server configuration detail
**Operating system:** Linux 5.4.0-65-generic 73-Ubuntu SMP Mon Jan 18 17:25:17 UTC 2021 x86_64
**Webserver:** Apache/2.4.38 (Debian) (apache2handler)
**Database:** mysql 10.5.8
**PHP version:**
7.4.14
Modules loaded: Core, date, libxml, openssl, pcre, sqlite3, zlib, ctype, curl, dom, fileinfo, filter, ftp, hash, iconv, json, mbstring, SPL, PDO, session, posix, Reflection, standard, SimpleXML, pdo_sqlite, Phar, tokenizer, xml, xmlreader, xmlwriter, mysqlnd, apache2handler, apcu, bcmath, exif, gd, gmp, imagick, intl, ldap, memcached, pcntl, pdo_mysql, pdo_pgsql, redis, sodium, zip, Zend OPcache
**Nextcloud version:** 20.0.6 - 20.0.6.1
**Updated from an older Nextcloud/ownCloud or fresh install:**
**Where did you install Nextcloud from:** unknown
<details><summary>Signing status</summary>
Array
(
)
</details>
<details><summary>List of activated apps</summary>
```
Enabled:
- accessibility: 1.6.0
- activity: 2.13.4
- announcementcenter: 4.0.1
- appointments: 1.8.1
- apporder: 0.11.0
- breezedark: 20.0.3
- bruteforcesettings: 2.0.1
- calendar: 2.1.3
- circles: 0.20.6
- cloud_federation_api: 1.3.0
- comments: 1.10.0
- contacts: 3.4.3
- contactsinteraction: 1.1.0
- dashboard: 7.0.0
- dav: 1.16.2
- deck: 1.2.4
- epubreader: 1.4.5
- event_update_notification: 1.2.0
- external: 3.7.2
- federatedfilesharing: 1.10.2
- federation: 1.10.1
- files: 1.15.0
- files_automatedtagging: 1.10.1
- files_markdown: 2.3.1
- files_mindmap: 0.0.24
- files_pdfviewer: 2.0.1
- files_retention: 1.9.0
- files_rightclick: 0.17.0
- files_sharing: 1.12.2
- files_texteditor: 2.14.0
- files_trashbin: 1.10.1
- files_versions: 1.13.0
- files_videoplayer: 1.9.0
- firstrunwizard: 2.9.0
- flow_notifications: 1.0.3
- flowupload: 1.1.2
- forms: 2.1.0
- groupfolders: 8.2.0
- impersonate: 1.7.0
- issuetemplate: 0.7.0
- logreader: 2.5.0
- lookup_server_connector: 1.8.0
- nextcloud_announcements: 1.9.0
- notes: 3.5.1
- notifications: 2.8.0
- oauth2: 1.8.0
- password_policy: 1.10.1
- pdfdraw: 0.1.2
- photos: 1.2.3
- polls: 1.7.5
- privacy: 1.4.0
- provisioning_api: 1.10.0
- quicknotes: 0.6.3
- quota_warning: 1.9.1
- recommendations: 0.8.0
- richdocuments: 3.7.14
- richdocumentscode: 6.4.403
- serverinfo: 1.10.0
- settings: 1.2.0
- sharebymail: 1.10.0
- side_menu: 1.22.0
- socialsharing_email: 2.1.0
- socialsharing_facebook: 2.1.0
- socialsharing_twitter: 2.1.0
- spreed: 10.0.5
- support: 1.3.0
- survey_client: 1.8.0
- systemtags: 1.10.0
- talk_simple_poll: 1.2.0
- tasks: 0.13.6
- theming: 1.11.0
- twofactor_backupcodes: 1.9.0
- updatenotification: 1.10.0
- user_saml: 3.3.4
- user_status: 1.0.1
- viewer: 1.4.0
- weather_status: 1.0.0
- whiteboard: 0.0.3
- workflowengine: 2.2.0
Disabled:
- admin_audit
- encryption
- files_external
- hsts
- registration
- text
- twofactor_email
- twofactor_nextcloud_notification
- user_ldap
- workflow_script
```
</details>
<details><summary>Configuration (config/config.php)</summary>
```
{
"htaccess.RewriteBase": "\/",
"memcache.local": "\\OC\\Memcache\\APCu",
"apps_paths": [
{
"path": "\/var\/www\/html\/apps",
"url": "\/apps",
"writable": false
},
{
"path": "\/var\/www\/html\/custom_apps",
"url": "\/custom_apps",
"writable": true
}
],
"instanceid": "***REMOVED SENSITIVE VALUE***",
"passwordsalt": "***REMOVED SENSITIVE VALUE***",
"secret": "***REMOVED SENSITIVE VALUE***",
"trusted_domains": [
"kgtz-nextcloud.frankmayer.net"
],
"datadirectory": "***REMOVED SENSITIVE VALUE***",
"dbtype": "mysql",
"version": "20.0.6.1",
"overwrite.cli.url": "http:\/\/kgtz-nextcloud.frankmayer.net",
"dbname": "***REMOVED SENSITIVE VALUE***",
"dbhost": "***REMOVED SENSITIVE VALUE***",
"dbport": "",
"dbtableprefix": "oc_",
"mysql.utf8mb4": true,
"dbuser": "***REMOVED SENSITIVE VALUE***",
"dbpassword": "***REMOVED SENSITIVE VALUE***",
"installed": true,
"overwriteprotocol": "https",
"mail_smtpmode": "smtp",
"mail_smtpsecure": "tls",
"mail_sendmailmode": "smtp",
"mail_from_address": "***REMOVED SENSITIVE VALUE***",
"mail_smtpauthtype": "LOGIN",
"mail_smtpauth": 1,
"mail_smtphost": "***REMOVED SENSITIVE VALUE***",
"mail_smtpport": "25",
"mail_smtpname": "***REMOVED SENSITIVE VALUE***",
"mail_smtppassword": "***REMOVED SENSITIVE VALUE***",
"mail_domain": "***REMOVED SENSITIVE VALUE***",
"maintenance": false,
"app_install_overwrite": [
"joplin",
"documents"
],
"updater.secret": "***REMOVED SENSITIVE VALUE***"
}
```
</details>
**Are you using external storage, if yes which one:** local/smb/sftp/...
**Are you using encryption:**
**Are you using an external user-backend, if yes which one:** LDAP/ActiveDirectory/Webdav/...
## Client configuration
**Browser:** Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:84.0) Gecko/20100101 Firefox/84.0
**Operating system:**
## Logs
<details><summary>Web server error log</summary>
```
Insert your web server log here
```
</details>
<details><summary>Nextcloud log</summary>
```
Insert your Nextcloud log here
```
</details>
<details><summary>Browser log</summary>
When linking succeeds, there are 2 consecutive successful calls to the server.
in my case:
Request URL: https://ADDRESS__/ocs/v2.php/collaboration/resources/deck-card/50?format=json
Request Method: POST
Status Code: 200
Referrer Policy: no-referrer
cache-control: no-cache, no-store, must-revalidate
content-encoding: gzip
content-length: 291
content-security-policy: default-src 'none';base-uri 'none';manifest-src 'self';frame-ancestors 'none'
content-type: application/json; charset=utf-8
with payload: {name: "αβγδεζηθικλμνξοπρστυφχψωαβγδεζηθ"}
Response
{"ocs":{"meta":{"status":"ok","statuscode":200,"message":"OK"},"data":{"id":45,"name":"\u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8\u03b9\u03ba\u03bb\u03bc\u03bd\u03be\u03bf\u03c0\u03c1\u03c3\u03c4\u03c5\u03c6\u03c7\u03c8\u03c9\u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8","resources":[{"type":"deck-card","id":"50","name":"IT (\u039c\u03b7\u03c7\u03b1\u03bd\u03bf\u03c1\u03b3\u03ac\u03bd\u03c9\u03c3\u03b7): \u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8\u03b9\u03ba\u03bb\u03bc\u03bd\u03be\u03bf\u03c0\u03c1\u03c3\u03c4\u03c5\u03c6\u03c7\u03c8\u03c9\u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8","link":"\/apps\/deck\/#\/board\/26\/card\/50","iconUrl":"\/core\/img\/actions\/toggle-pictures.svg"}]}}}
and
Request URL: https://ADDRESS__/ocs/v2.php/collaboration/resources/collections/45?format=json
Request Method: POST
Status Code: 200
Referrer Policy: no-referrer
cache-control: no-cache, no-store, must-revalidate
content-encoding: gzip
content-length: 334
content-security-policy: default-src 'none';base-uri 'none';manifest-src 'self';frame-ancestors 'none'
content-type: application/json; charset=utf-8
with payload: "{resourceType: "deck-card", resourceId: "46"}"
and response:
{"ocs":{"meta":{"status":"ok","statuscode":200,"message":"OK"},"data":{"id":45,"name":"\u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8\u03b9\u03ba\u03bb\u03bc\u03bd\u03be\u03bf\u03c0\u03c1\u03c3\u03c4\u03c5\u03c6\u03c7\u03c8\u03c9\u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8","resources":[{"type":"deck-card","id":"50","name":"IT (\u039c\u03b7\u03c7\u03b1\u03bd\u03bf\u03c1\u03b3\u03ac\u03bd\u03c9\u03c3\u03b7): \u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8\u03b9\u03ba\u03bb\u03bc\u03bd\u03be\u03bf\u03c0\u03c1\u03c3\u03c4\u03c5\u03c6\u03c7\u03c8\u03c9\u03b1\u03b2\u03b3\u03b4\u03b5\u03b6\u03b7\u03b8","link":"\/apps\/deck\/#\/board\/26\/card\/50","iconUrl":"\/core\/img\/actions\/toggle-pictures.svg"},{"type":"deck-card","id":"46","name":"\u03a0\u03c1\u03bf\u03c3\u03c9\u03c0\u03b9\u03ba\u03ac: test file link","link":"\/apps\/deck\/#\/board\/8\/card\/46","iconUrl":"\/core\/img\/actions\/toggle-pictures.svg"}]}}}
When it fails, there is only the first request which gets executed and receives a 400 error
Request URL: https://ADDRESS__/ocs/v2.php/collaboration/resources/deck-card/50?format=json
Request Method: POST
Status Code: 400
Referrer Policy: no-referrer
cache-control: no-cache, no-store, must-revalidate
content-length: 79
content-security-policy: default-src 'none';base-uri 'none';manifest-src 'self';frame-ancestors 'none'
content-type: application/json; charset=utf-8
with payload: "{name: "αβγδεζηθικλμνξοπρστυφχψωαβγδεζηθι"}"
and response: "{"ocs":{"meta":{"status":"failure","statuscode":400,"message":null},"data":[]}}"
</details>