I just narrowed the issue that persists with NC 31 and OO 9.2.1: now it seems to happen only with LDAP backed accounts. Here is the log from an LDAP user, whose displayName differs from its samAccountname (no log with any user in NC database):
{"reqId":"1WRCCK9bQ0R9FL39k6jS","level":3,"time":"2025-12-30T16:38:12+00:00","remoteAddr":"172.21.3.251","user":"--","app":"core","method":"GET","url":"/ocs/v2.php/cloud/user","message":"Renewing session token failed: Token does not exist: token does not exist","userAgent":"Documents/9.2.1 (com.onlyoffice.Documents; build:1173; iOS 18.7.2) Alamofire/5.10.2","version":"31.0.12.3","exception":{"Exception":"OC\\Authentication\\Exceptions\\InvalidTokenException","Message":"Token does not exist: token does not exist","Code":0,"Trace":[{"file":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/PublicKeyTokenProvider.php","line":232,"function":"getToken","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/usr/local/www/apache24/data/box/lib/public/AppFramework/Db/TTransactional.php","line":45,"function":"OC\\Authentication\\Token\\{closure}","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/PublicKeyTokenProvider.php","line":231,"function":"atomic","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->"},{"file":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/Manager.php","line":158,"function":"renewSessionToken","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->"},{"file":"/usr/local/www/apache24/data/box/lib/private/User/Session.php","line":883,"function":"renewSessionToken","class":"OC\\Authentication\\Token\\Manager","type":"->"},{"file":"/usr/local/www/apache24/data/box/lib/base.php","line":1145,"function":"loginWithCookie","class":"OC\\User\\Session","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/usr/local/www/apache24/data/box/ocs/v1.php","line":46,"function":"handleLogin","class":"OC","type":"::"},{"file":"/usr/local/www/apache24/data/box/ocs/v2.php","line":7,"args":["/usr/local/www/apache24/data/box/ocs/v1.php"],"function":"require_once"}],"File":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/PublicKeyTokenProvider.php","Line":165,"Previous":{"Exception":"OCP\\AppFramework\\Db\\DoesNotExistException","Message":"token does not exist","Code":0,"Trace":[{"file":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/PublicKeyTokenProvider.php","line":157,"function":"getToken","class":"OC\\Authentication\\Token\\PublicKeyTokenMapper","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/PublicKeyTokenProvider.php","line":232,"function":"getToken","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/usr/local/www/apache24/data/box/lib/public/AppFramework/Db/TTransactional.php","line":45,"function":"OC\\Authentication\\Token\\{closure}","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/PublicKeyTokenProvider.php","line":231,"function":"atomic","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->"},{"file":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/Manager.php","line":158,"function":"renewSessionToken","class":"OC\\Authentication\\Token\\PublicKeyTokenProvider","type":"->"},{"file":"/usr/local/www/apache24/data/box/lib/private/User/Session.php","line":883,"function":"renewSessionToken","class":"OC\\Authentication\\Token\\Manager","type":"->"},{"file":"/usr/local/www/apache24/data/box/lib/base.php","line":1145,"function":"loginWithCookie","class":"OC\\User\\Session","type":"->","args":["*** sensitive parameters replaced ***"]},{"file":"/usr/local/www/apache24/data/box/ocs/v1.php","line":46,"function":"handleLogin","class":"OC","type":"::"},{"file":"/usr/local/www/apache24/data/box/ocs/v2.php","line":7,"args":["/usr/local/www/apache24/data/box/ocs/v1.php"],"function":"require_once"}],"File":"/usr/local/www/apache24/data/box/lib/private/Authentication/Token/PublicKeyTokenMapper.php","Line":81},"message":"Renewing session token failed: Token does not exist: token does not exist","user":"demo","exception":{},"CustomMessage":"Renewing session token failed: Token does not exist: token does not exist"}}
{"reqId":"6n4H4rzHNl2ipzjaUhpZ","level":3,"time":"2025-12-30T16:38:32+00:00","remoteAddr":"172.21.3.251","user":"--","app":"core","method":"PROPFIND","url":"/remote.php/dav/files/demo/Documents","message":"App token login name does not match","userAgent":"Documents/1173 CFNetwork/3826.600.41 Darwin/24.6.0","version":"31.0.12.3","data":{"tokenLoginName":"demo","sessionLoginName":"Demo User","app":"core","user":"demo"}}
{"reqId":"6n4H4rzHNl2ipzjaUhpZ","level":2,"time":"2025-12-30T16:38:32+00:00","remoteAddr":"172.21.3.251","user":"--","app":"core","method":"PROPFIND","url":"/remote.php/dav/files/demo/Documents","message":"Login failed: 'Demo User' (Remote IP: '172.21.3.251')","userAgent":"Documents/1173 CFNetwork/3826.600.41 Darwin/24.6.0","version":"31.0.12.3","data":{"app":"core"}}
And thanks for your support!
