]>
git.ipfire.org Git - thirdparty/util-linux.git/blob - login-utils/ch-common.c
2 * chfn and chsh shared functions
4 * this program is free software. you can redistribute it and
5 * modify it under the terms of the gnu general public license.
6 * there is no warranty.
15 #include "ch-common.h"
18 * illegal_passwd_chars () -
19 * check whether a string contains illegal characters
21 int illegal_passwd_chars(const char *str
)
23 const char illegal
[] = ",:=\"\n";
24 const size_t len
= strlen(str
);
27 if (strpbrk(str
, illegal
))
29 for (i
= 0; i
< len
; i
++) {