-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: Trying to access array offset on value of type bool at /lib/private/Files/Storage/Wrapper/Encryption.php#441
#27692
Comments
maybe the same as #21578 |
These are different errors, the other one has already been fixed, this is another error, it's when sending a file. |
Same issue on NC 21.0.3 & 22 deleting files from External Storage SMB with encryption
|
I think they're not paying attention to this error, or they don't care about encryption. |
@AndyXheli I am no longer using the encryption app (I disabled it) and I do no longer support any code I wrote for that app. |
Still an issue on NC 22.1.1 happens while using external storage SMB |
Yeah just noticed I have these error as well, only on an external storage, just a local folder with encryption disabled on this folder. And I do have the patch from #21578 applied on my instance. |
The same thing is happening to me while using encryption with an Amazon S3 external storage on NextCloud version 22.1.1. edit: I'm also running inside of docker |
Still receiving these errors with Nextcloud 22.2.3, External Storage connected to the local filesystem. In my case, the error is only triggered with WebDAV access.
|
Using 23.0.3 Stacktrace as json format (click me)
{
"reqId": "xxxxxxx",
"level": 4,
"time": "2022-04-06T09:30:16+00:00",
"remoteAddr": "xx.xx.xx.xx",
"user": "admin",
"app": "webdav",
"method": "DELETE",
"url": "/remote.php/dav/files/admin/Begleitbuch/Readme.md",
"message": "Call to a member function getId() on array",
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:99.0) Gecko/20100101 Firefox/99.0",
"version": "23.0.3.2",
"exception": {
"Exception": "Error",
"Message": "Call to a member function getId() on array",
"Code": 0,
"Trace": [
{
"file": "/var/www/html/lib/private/Files/Cache/Wrapper/CacheWrapper.php",
"line": 184,
"function": "remove",
"class": "OC\\Files\\Cache\\Cache",
"type": "->",
"args": [
"Readme.md"
]
},
{
"file": "/var/www/html/lib/private/Files/Cache/Updater.php",
"line": 159,
"function": "remove",
"class": "OC\\Files\\Cache\\Wrapper\\CacheWrapper",
"type": "->",
"args": [
"Readme.md"
]
},
{
"file": "/var/www/html/lib/private/Files/View.php",
"line": 329,
"function": "remove",
"class": "OC\\Files\\Cache\\Updater",
"type": "->",
"args": [
"Readme.md"
]
},
{
"file": "/var/www/html/lib/private/Files/View.php",
"line": 1183,
"function": "removeUpdate",
"class": "OC\\Files\\View",
"type": "->",
"args": [
{
"__class__": "OCA\\Files_Trashbin\\Storage",
"cache": {
"__class__": "OC\\Files\\Cache\\Cache"
},
"scanner": {
"__class__": "OC\\Files\\Cache\\Scanner"
},
"watcher": null,
"propagator": {
"__class__": "OC\\Files\\Cache\\Propagator"
},
"updater": {
"__class__": "OC\\Files\\Cache\\Updater"
}
},
"Readme.md"
]
},
{
"file": "/var/www/html/lib/private/Files/View.php",
"line": 728,
"function": "basicOperation",
"class": "OC\\Files\\View",
"type": "->",
"args": [
"unlink",
"/Begleitbuch/Readme.md",
[
"delete"
]
]
},
{
"file": "/var/www/html/apps/dav/lib/Connector/Sabre/File.php",
"line": 495,
"function": "unlink",
"class": "OC\\Files\\View",
"type": "->",
"args": [
"/Begleitbuch/Readme.md"
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Tree.php",
"line": 179,
"function": "delete",
"class": "OCA\\DAV\\Connector\\Sabre\\File",
"type": "->",
"args": []
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/CorePlugin.php",
"line": 281,
"function": "delete",
"class": "Sabre\\DAV\\Tree",
"type": "->",
"args": [
"files/admin/Begleitbuch/Readme.md"
]
},
{
"file": "/var/www/html/3rdparty/sabre/event/lib/WildcardEmitterTrait.php",
"line": 89,
"function": "httpDelete",
"class": "Sabre\\DAV\\CorePlugin",
"type": "->",
"args": [
{
"__class__": "Sabre\\HTTP\\Request"
},
{
"__class__": "Sabre\\HTTP\\Response"
}
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 472,
"function": "emit",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
"method:DELETE",
[
{
"__class__": "Sabre\\HTTP\\Request"
},
{
"__class__": "Sabre\\HTTP\\Response"
}
]
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 253,
"function": "invokeMethod",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
{
"__class__": "Sabre\\HTTP\\Request"
},
{
"__class__": "Sabre\\HTTP\\Response"
}
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 321,
"function": "start",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/apps/dav/lib/Server.php",
"line": 339,
"function": "exec",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/apps/dav/appinfo/v2/remote.php",
"line": 35,
"function": "exec",
"class": "OCA\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/remote.php",
"line": 166,
"args": [
"/var/www/html/apps/dav/appinfo/v2/remote.php"
],
"function": "require_once"
}
],
"File": "/var/www/html/lib/private/Files/Cache/Cache.php",
"Line": 543,
"CustomMessage": "--"
},
"id": "xxxxxx"
} {
"reqId": "xxxxx",
"level": 3,
"time": "2022-04-06T09:30:16+00:00",
"remoteAddr": "xx.xx.xx.xx",
"user": "admin",
"app": "PHP",
"method": "DELETE",
"url": "/remote.php/dav/files/admin/Begleitbuch/Readme.md",
"message": "Trying to access array offset on value of type bool at /var/www/html/lib/private/Files/Storage/Wrapper/Encryption.php#441",
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:99.0) Gecko/20100101 Firefox/99.0",
"version": "23.0.3.2",
"exception": {
"Exception": "Error",
"Message": "Trying to access array offset on value of type bool at /var/www/html/lib/private/Files/Storage/Wrapper/Encryption.php#441",
"Code": 0,
"Trace": [
{
"file": "/var/www/html/lib/private/Files/Storage/Wrapper/Encryption.php",
"line": 441,
"function": "onError",
"class": "OC\\Log\\ErrorHandler",
"type": "::",
"args": [
2,
"Trying to access array offset on value of type bool",
"/var/www/html/lib/private/Files/Storage/Wrapper/Encryption.php",
441
]
},
{
"file": "/var/www/html/lib/private/Files/Storage/Wrapper/Wrapper.php",
"line": 301,
"function": "fopen",
"class": "OC\\Files\\Storage\\Wrapper\\Encryption",
"type": "->",
"args": [
"Readme.md",
"r"
]
},
{
"file": "/var/www/html/lib/private/Files/Storage/Wrapper/Encryption.php",
"line": 794,
"function": "fopen",
"class": "OC\\Files\\Storage\\Wrapper\\Wrapper",
"type": "->",
"args": [
"Readme.md",
"r"
]
},
{
"file": "/var/www/html/lib/private/Files/Storage/Wrapper/Encryption.php",
"line": 651,
"function": "copyBetweenStorage",
"class": "OC\\Files\\Storage\\Wrapper\\Encryption",
"type": "->",
"args": [
{
"__class__": "OCA\\Files_Trashbin\\Storage",
"cache": {
"__class__": "OC\\Files\\Cache\\Cache"
},
"scanner": {
"__class__": "OC\\Files\\Cache\\Scanner"
},
"watcher": null,
"propagator": {
"__class__": "OC\\Files\\Cache\\Propagator"
},
"updater": {
"__class__": "OC\\Files\\Cache\\Updater"
}
},
"Readme.md",
"files_trashbin/files/Readme.md.d1649237416",
true,
true
]
},
{
"file": "/var/www/html/lib/private/Files/Storage/Wrapper/Wrapper.php",
"line": 595,
"function": "moveFromStorage",
"class": "OC\\Files\\Storage\\Wrapper\\Encryption",
"type": "->",
"args": [
{
"__class__": "OCA\\Files_Trashbin\\Storage",
"cache": {
"__class__": "OC\\Files\\Cache\\Cache"
},
"scanner": {
"__class__": "OC\\Files\\Cache\\Scanner"
},
"watcher": null,
"propagator": {
"__class__": "OC\\Files\\Cache\\Propagator"
},
"updater": {
"__class__": "OC\\Files\\Cache\\Updater"
}
},
"Readme.md",
"files_trashbin/files/Readme.md.d1649237416"
]
},
{
"file": "/var/www/html/apps/files_trashbin/lib/Storage.php",
"line": 239,
"function": "moveFromStorage",
"class": "OC\\Files\\Storage\\Wrapper\\Wrapper",
"type": "->",
"args": [
{
"__class__": "OCA\\Files_Trashbin\\Storage",
"cache": {
"__class__": "OC\\Files\\Cache\\Cache"
},
"scanner": {
"__class__": "OC\\Files\\Cache\\Scanner"
},
"watcher": null,
"propagator": {
"__class__": "OC\\Files\\Cache\\Propagator"
},
"updater": {
"__class__": "OC\\Files\\Cache\\Updater"
}
},
"Readme.md",
"files_trashbin/files/Readme.md.d1649237416"
]
},
{
"file": "/var/www/html/apps/files_trashbin/lib/Trashbin.php",
"line": 322,
"function": "moveFromStorage",
"class": "OCA\\Files_Trashbin\\Storage",
"type": "->",
"args": [
{
"__class__": "OCA\\Files_Trashbin\\Storage",
"cache": {
"__class__": "OC\\Files\\Cache\\Cache"
},
"scanner": {
"__class__": "OC\\Files\\Cache\\Scanner"
},
"watcher": null,
"propagator": {
"__class__": "OC\\Files\\Cache\\Propagator"
},
"updater": {
"__class__": "OC\\Files\\Cache\\Updater"
}
},
"Readme.md",
"files_trashbin/files/Readme.md.d1649237416"
]
},
{
"file": "/var/www/html/apps/files_trashbin/lib/Trash/LegacyTrashBackend.php",
"line": 107,
"function": "move2trash",
"class": "OCA\\Files_Trashbin\\Trashbin",
"type": "::",
"args": [
"Begleitbuch/Readme.md"
]
},
{
"file": "/var/www/html/apps/files_trashbin/lib/Trash/TrashManager.php",
"line": 102,
"function": "moveToTrash",
"class": "OCA\\Files_Trashbin\\Trash\\LegacyTrashBackend",
"type": "->",
"args": [
{
"__class__": "OCA\\Files_Trashbin\\Storage",
"cache": {
"__class__": "OC\\Files\\Cache\\Cache"
},
"scanner": {
"__class__": "OC\\Files\\Cache\\Scanner"
},
"watcher": null,
"propagator": {
"__class__": "OC\\Files\\Cache\\Propagator"
},
"updater": {
"__class__": "OC\\Files\\Cache\\Updater"
}
},
"Readme.md"
]
},
{
"file": "/var/www/html/apps/files_trashbin/lib/Storage.php",
"line": 202,
"function": "moveToTrash",
"class": "OCA\\Files_Trashbin\\Trash\\TrashManager",
"type": "->",
"args": [
{
"__class__": "OCA\\Files_Trashbin\\Storage",
"cache": {
"__class__": "OC\\Files\\Cache\\Cache"
},
"scanner": {
"__class__": "OC\\Files\\Cache\\Scanner"
},
"watcher": null,
"propagator": {
"__class__": "OC\\Files\\Cache\\Propagator"
},
"updater": {
"__class__": "OC\\Files\\Cache\\Updater"
}
},
"Readme.md"
]
},
{
"file": "/var/www/html/apps/files_trashbin/lib/Storage.php",
"line": 102,
"function": "doDelete",
"class": "OCA\\Files_Trashbin\\Storage",
"type": "->",
"args": [
"Readme.md",
"unlink"
]
},
{
"file": "/var/www/html/lib/private/Files/View.php",
"line": 1171,
"function": "unlink",
"class": "OCA\\Files_Trashbin\\Storage",
"type": "->",
"args": [
"Readme.md"
]
},
{
"file": "/var/www/html/lib/private/Files/View.php",
"line": 728,
"function": "basicOperation",
"class": "OC\\Files\\View",
"type": "->",
"args": [
"unlink",
"/Begleitbuch/Readme.md",
[
"delete"
]
]
},
{
"file": "/var/www/html/apps/dav/lib/Connector/Sabre/File.php",
"line": 495,
"function": "unlink",
"class": "OC\\Files\\View",
"type": "->",
"args": [
"/Begleitbuch/Readme.md"
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Tree.php",
"line": 179,
"function": "delete",
"class": "OCA\\DAV\\Connector\\Sabre\\File",
"type": "->",
"args": []
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/CorePlugin.php",
"line": 281,
"function": "delete",
"class": "Sabre\\DAV\\Tree",
"type": "->",
"args": [
"files/admin/Begleitbuch/Readme.md"
]
},
{
"file": "/var/www/html/3rdparty/sabre/event/lib/WildcardEmitterTrait.php",
"line": 89,
"function": "httpDelete",
"class": "Sabre\\DAV\\CorePlugin",
"type": "->",
"args": [
{
"__class__": "Sabre\\HTTP\\Request"
},
{
"__class__": "Sabre\\HTTP\\Response"
}
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 472,
"function": "emit",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
"method:DELETE",
[
{
"__class__": "Sabre\\HTTP\\Request"
},
{
"__class__": "Sabre\\HTTP\\Response"
}
]
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 253,
"function": "invokeMethod",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": [
{
"__class__": "Sabre\\HTTP\\Request"
},
{
"__class__": "Sabre\\HTTP\\Response"
}
]
},
{
"file": "/var/www/html/3rdparty/sabre/dav/lib/DAV/Server.php",
"line": 321,
"function": "start",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/apps/dav/lib/Server.php",
"line": 339,
"function": "exec",
"class": "Sabre\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/apps/dav/appinfo/v2/remote.php",
"line": 35,
"function": "exec",
"class": "OCA\\DAV\\Server",
"type": "->",
"args": []
},
{
"file": "/var/www/html/remote.php",
"line": 166,
"args": [
"/var/www/html/apps/dav/appinfo/v2/remote.php"
],
"function": "require_once"
}
],
"File": "/var/www/html/lib/private/Log/ErrorHandler.php",
"Line": 92,
"CustomMessage": "--"
},
"id": "xxxxxxxx"
} |
Same for me. Happens only on SMB folders when deleting files. Exact same behavior on 23.0.4 Encryption is disabled btw. |
Still an issue on NC 25.0.1
|
@icewind1991 Can you please get some attentions on this ? Looks like when having encryption enabled on NC 25 and i created a doc via external smb share it dose not work just get error and the doc looks corrupt
|
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as off-topic.
This comment was marked as off-topic.
Same here on SFTP/Webdav, let me know if additional logging / testing is needed. Would like to help solve this asap! It seems I'm able to copy/move files from anywhere and they get properly encrypted on both Webdav and SFTP (File content encrypted upon opening not via NC) but when trying to recursively move or copy a folder (either by dragging or selecting move/copy) it results in Please advise. ps, it seems file/folder names are still intact only the content is encrypted, could anyone confirm this is supposed be? I recall it does, just want to be sure. |
This comment was marked as resolved.
This comment was marked as resolved.
I believe this is fixed (at least in >=NC26) via #34724. Is anyone on this thread that has moved to at least NC26 still experiencing this behavior? |
@joshtrichards I've been following this issue because I had the same problem and can confirm that this no longer happens with WebDAV (NC27.0.2). |
@joshtrichards I'm on nc27 and am still having this error occur! [PHP] Fout: Trying to access array offset on value of type bool at /var/www/nextcloud/lib/private/Files/Storage/Wrapper/Encryption.php#453 |
Not sure the underlying cause, but did a little digging today. Leaving a few notes here for next time: server/lib/private/Files/Storage/Wrapper/Encryption.php Lines 447 to 453 in cde21ff
Questions to follow-up on:
Triggering this code path should only be possible in environments where there are no headers on the encrypted files (old installations only I believe)... though if we're setting |
Error: Trying to access array offset on value of type bool at /lib/private/Files/Storage/Wrapper/Encryption.php#441
Apache dockered system, with server-side encryption. Every time a file is uploaded it causes this title error.
Nextcloud 21.0.2 - docker (apache version 21)
Staff, server-side encryption enabled, I send a file to nextcloud and keep giving this error:
How does the error happen?
Just upload any file to nextcloud with encryption enabled.
My docker-compose.yml
The text was updated successfully, but these errors were encountered: