Ignore:
Timestamp:
Dec 20, 2016, 4:07:32 PM (7 years ago)
Author:
Bruno Cornec
Message:

New 3?3 banch for incorporation of latest busybox 1.25. Changing minor version to handle potential incompatibilities.

Location:
branches/3.3
Files:
1 edited
1 copied

Legend:

Unmodified
Added
Removed
  • branches/3.3/mindi-busybox/loginutils/passwd.c

    r3232 r3621  
    33 * Licensed under GPLv2 or later, see file LICENSE in this source tree.
    44 */
     5//config:config PASSWD
     6//config:   bool "passwd"
     7//config:   default y
     8//config:   select FEATURE_SYSLOG
     9//config:   help
     10//config:     passwd changes passwords for user and group accounts. A normal user
     11//config:     may only change the password for his/her own account, the super user
     12//config:     may change the password for any account. The administrator of a group
     13//config:     may change the password for the group.
     14//config:
     15//config:     Note that Busybox binary must be setuid root for this applet to
     16//config:     work properly.
     17//config:
     18//config:config FEATURE_PASSWD_WEAK_CHECK
     19//config:   bool "Check new passwords for weakness"
     20//config:   default y
     21//config:   depends on PASSWD
     22//config:   help
     23//config:     With this option passwd will refuse new passwords which are "weak".
     24
     25//applet:/* Needs to be run by root or be suid root - needs to change /etc/{passwd,shadow}: */
     26//applet:IF_PASSWD(APPLET(passwd, BB_DIR_USR_BIN, BB_SUID_REQUIRE))
     27
     28//kbuild:lib-$(CONFIG_PASSWD) += passwd.o
    529
    630//usage:#define passwd_trivial_usage
     
    1741#include <syslog.h>
    1842#include <sys/resource.h> /* setrlimit */
    19 
    20 static void nuke_str(char *str)
    21 {
    22     if (str) memset(str, 0, strlen(str));
    23 }
    2443
    2544static char* new_password(const struct passwd *pw, uid_t myuid, const char *algo)
     
    212231    if (rc < 0)
    213232        bb_error_msg_and_die("can't update password file %s", filename);
    214     bb_info_msg("Password for %s changed by %s", name, myname);
     233    bb_error_msg("password for %s changed by %s", name, myname);
    215234
    216235    /*if (ENABLE_FEATURE_CLEAN_UP) free(newp); - can't, it may be non-malloced */
Note: See TracChangeset for help on using the changeset viewer.