max group name length

David Landgren david at landgren.net
Thu Jun 26 01:43:52 PDT 2003


David Bear wrote:

> was just trying to determine the maximum string length of a group
> name.
> 
> found 
> struct group {
>              char    *gr_name;       /* group name */
> 
> but no size.
> 
> any pointers (with limits)?

Hmm, I had a browse through the kernel source for a while but didn't 
find anything definite. What I do know is that you should endeavour to 
keep the length no greater than 8. Up to 15 is probably ok as well on 
modern kernels, and group names longer than 15 is getting a bit silly.

Sorry no to have anything more precise.

David



More information about the freebsd-questions mailing list