haihua yang
2023-Nov-21 02:08 UTC
[Samba] is it safe to encode/decode uid_t/gid_t in 4 bytes?
Hi, Samba internally uses 8 bytes to encode/decode uid_t/gid_t, e.g., _PUBLIC_ enum ndr_err_code ndr_push_uid_t(struct ndr_push *ndr, int ndr_flags, uid_t u) { NDR_PUSH_CHECK_FLAGS(ndr, ndr_flags); return ndr_push_hyper(ndr, NDR_SCALARS, (uint64_t)u); } I want to know if it is safe to use 4 bytes to reduce the size in storing security_info in tdb. I am not aware of if there is any platform on which uid_t or gid_t is 64bits, and it seems that the encoded data is not sent over the network. Thanks,
Apparently Analagous Threads
- Samba 4.4.5 exists with segmention fault on FreeBSD 10.3 during domain provision
- Samba 4.4.5 exists with segmention fault on FreeBSD 10.3 during domain provision
- Windows AD report KRB5KDC_ERR_ETYPE_NOSUPP when client request AES ticket
- why auth3_check_password load smb.conf again
- openssh-2.9.9p2 assumes pid_t, uid_t, etc. are not 'long'