Hi,
newuidmap / newgidmap consult /etc/nsswitch.conf to decide where to
get information on allowed sbuids from.
The /etc/subuid and /etc/subgid files are only used if the subid filed
in /etc/nsswitch.conf is either unset or set to files (see subuid(5)).
Otherwise the information is retrived by calling some function in a
shared object file derived from the subid value in /etc/nsswitch.conf.
I propose the retrieve the subuids/subgids by calling the getsubids
command included in the uidmap package.
I proposed a similar change to sbuild here:
https://salsa.debian.org/debian/sbuild/-/merge_requests/222
Regards,
Tobias Wiese