Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 21 Oct 2014 21:11:25 +0000 (UTC)
From:      Xin LI <delphij@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org
Subject:   svn commit: r273427 - stable/9/usr.sbin/pw
Message-ID:  <201410212111.s9LLBPho095230@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: delphij
Date: Tue Oct 21 21:11:25 2014
New Revision: 273427
URL: https://svnweb.freebsd.org/changeset/base/273427

Log:
  MFC r272833 (des):
  
  Two more places where login_setcryptfmt() defaults to MD5 were missed
  in r252688.

Modified:
  stable/9/usr.sbin/pw/pw_user.c
Directory Properties:
  stable/9/usr.sbin/pw/   (props changed)

Modified: stable/9/usr.sbin/pw/pw_user.c
==============================================================================
--- stable/9/usr.sbin/pw/pw_user.c	Tue Oct 21 21:09:54 2014	(r273426)
+++ stable/9/usr.sbin/pw/pw_user.c	Tue Oct 21 21:11:25 2014	(r273427)
@@ -586,7 +586,7 @@ pw_user(struct userconf * cnf, int mode,
 		pwd->pw_dir = pw_homepolicy(cnf, args, pwd->pw_name);
 		pwd->pw_shell = pw_shellpolicy(cnf, args, NULL);
 		lc = login_getpwclass(pwd);
-		if (lc == NULL || login_setcryptfmt(lc, "md5", NULL) == NULL)
+		if (lc == NULL || login_setcryptfmt(lc, "sha512", NULL) == NULL)
 			warn("setting crypt(3) format");
 		login_close(lc);
 		pwd->pw_passwd = pw_password(cnf, args, pwd->pw_name);
@@ -661,7 +661,7 @@ pw_user(struct userconf * cnf, int mode,
 			} else {
 				lc = login_getpwclass(pwd);
 				if (lc == NULL ||
-				    login_setcryptfmt(lc, "md5", NULL) == NULL)
+				    login_setcryptfmt(lc, "sha512", NULL) == NULL)
 					warn("setting crypt(3) format");
 				login_close(lc);
 				pwd->pw_passwd = pw_pwcrypt(line);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201410212111.s9LLBPho095230>