NIS maps value length increase to 16m
Konstantin Belousov
kostikbel at gmail.com
Tue Aug 6 07:00:32 UTC 2019
Apparently, NIS is still in use even in large enterprise environments,
not everything was consumed by LDAP. And there, Linux added a quirk
very long time ago, in 2013 at least, see
https://marc.info/?l=fedora-extras-commits&m=136675043230000&w=2
What they did is the increase of the longest allowed key value (and
key name) in a map, from Sun-defined 1024 to 16M. This change is
backward-compatible, in the sense that either old NIS master or old
NIS client are protocol-compatible with the updated masters and
clients, assuming that the maps only export values limited to 1024
bytes in length. On the other hand, a new client can use much larger
values. This works because values are specified in yp XDR as opaque
variadic-length arrays.
An example where this is useful is the environment with very large
automount maps exported by NIS. For obvious reasons, FreeBSD cannot
function in such settings.
I wrote the patch to bump the limit in FreeBSD NIS implementation,
both in client and in servers, see
https://reviews.freebsd.org/D20900
If you are interested in the NIS code, please review. I want to commit
the change into HEAD in approximately two weeks from now.
More information about the freebsd-current
mailing list