This looks like a regression introduced by the recent security fixes. As a workaround it might be possible to use the username map script based on the example in https://bugzilla.samba.org/show_bug.cgi?id=14901#c0. Reported-at: https://lists.samba.org/archive/samba/2021-November/238720.html
This bug was referenced in samba master: 1e61de8306604a0d3858342df8a1d2412d8d418b
Created attachment 17045 [details] Patch for v4-15-test
Created attachment 17046 [details] Patch for v4-14-test
Created attachment 17047 [details] Patches for v4-13-test
Reassigning to Jule for inclusion in 4.13, 4.14 and 4.15.
(In reply to Ralph Böhme from comment #5) Pushed to autobuild-v4-{15,14,13}-test
This bug was referenced in samba v4-15-test: 5db0cb09e94ad249282b94dea5f21201ed3a1c95
This bug was referenced in samba v4-15-stable (Release samba-4.15.3): 5db0cb09e94ad249282b94dea5f21201ed3a1c95
This bug was referenced in samba v4-14-test: b0d67dc3d42b81e5e35da26a333c4fcd67baab1f
This bug was referenced in samba v4-13-test: 1e27b820dff2ff9ef99b4d5dc8e85548a2ad92b4
Closing out bug report. Thanks!
This bug was referenced in samba v4-13-stable (Release samba-4.13.15): 1e27b820dff2ff9ef99b4d5dc8e85548a2ad92b4
This bug was referenced in samba v4-14-stable (Release samba-4.14.11): b0d67dc3d42b81e5e35da26a333c4fcd67baab1f