[Pkg-shadow-commits] r3419 - in debian/trunk/tests/grouptools/chgpasswd: . 06_chgpasswd_usage 06_chgpasswd_usage/config 06_chgpasswd_usage/config/etc 06_chgpasswd_usage/config/etc/default 06_chgpasswd_usage/data 07_chgpasswd_usage_bad_option 07_chgpasswd_usage_bad_option/config 07_chgpasswd_usage_bad_option/config/etc 07_chgpasswd_usage_bad_option/config/etc/default 07_chgpasswd_usage_bad_option/data 08_chgpasswd_usage-e-m_exclusive 08_chgpasswd_usage-e-m_exclusive/config 08_chgpasswd_usage-e-m_exclusive/config/etc 08_chgpasswd_usage-e-m_exclusive/config/etc/default 08_chgpasswd_usage-e-m_exclusive/data 09_chgpasswd_usage-e-c_exclusive 09_chgpasswd_usage-e-c_exclusive/config 09_chgpasswd_usage-e-c_exclusive/config/etc 09_chgpasswd_usage-e-c_exclusive/config/etc/default 09_chgpasswd_usage-e-c_exclusive/data 10_chgpasswd_usage-m-c_exclusive 10_chgpasswd_usage-m-c_exclusive/config 10_chgpasswd_usage-m-c_exclusive/config/etc 10_chgpasswd_usage-m-c_exclusive/config/etc/default 10_chgpasswd_usage-m-c_exclusive/data 11_chgpasswd_usage-s_without-c 11_chgpasswd_usage-s_without-c/config 11_chgpasswd_usage-s_without-c/config/etc 11_chgpasswd_usage-s_without-c/config/etc/default 11_chgpasswd_usage-s_without-c/data 12_chgpasswd_usage-s_invalid 12_chgpasswd_usage-s_invalid/config 12_chgpasswd_usage-s_invalid/config/etc 12_chgpasswd_usage-s_invalid/config/etc/default 12_chgpasswd_usage-s_invalid/data 13_chgpasswd_usage-c_invalid 13_chgpasswd_usage-c_invalid/config 13_chgpasswd_usage-c_invalid/config/etc 13_chgpasswd_usage-c_invalid/config/etc/default 13_chgpasswd_usage-c_invalid/data 14_chgpasswd_password_encrypted 14_chgpasswd_password_encrypted/config 14_chgpasswd_password_encrypted/config/etc 14_chgpasswd_password_encrypted/data 15_chgpasswd_password_md5 15_chgpasswd_password_md5/config 15_chgpasswd_password_md5/config/etc 15_chgpasswd_password_md5/data 16_chgpasswd_password_NONE 16_chgpasswd_password_NONE/config 16_chgpasswd_password_NONE/config/etc 16_chgpasswd_password_NONE/data 17_chgpasswd_password_MD5 17_chgpasswd_password_MD5/config 17_chgpasswd_password_MD5/config/etc 17_chgpasswd_password_MD5/data 18_chgpasswd_password_DES 18_chgpasswd_password_DES/config 18_chgpasswd_password_DES/config/etc 18_chgpasswd_password_DES/data 19_chgpasswd_password_SHA256 19_chgpasswd_password_SHA256/config 19_chgpasswd_password_SHA256/config/etc 19_chgpasswd_password_SHA256/data 20_chgpasswd_password_SHA256_rounds_900 20_chgpasswd_password_SHA256_rounds_900/config 20_chgpasswd_password_SHA256_rounds_900/config/etc 20_chgpasswd_password_SHA256_rounds_900/data 21_chgpasswd_password_SHA256_rounds_9000 21_chgpasswd_password_SHA256_rounds_9000/config 21_chgpasswd_password_SHA256_rounds_9000/config/etc 21_chgpasswd_password_SHA256_rounds_9000/data 22_chgpasswd_password_SHA512 22_chgpasswd_password_SHA512/config 22_chgpasswd_password_SHA512/config/etc 22_chgpasswd_password_SHA512/data 23_chgpasswd_password_SHA512_rounds_900 23_chgpasswd_password_SHA512_rounds_900/config 23_chgpasswd_password_SHA512_rounds_900/config/etc 23_chgpasswd_password_SHA512_rounds_900/data 24_chgpasswd_password_SHA512_rounds_9000 24_chgpasswd_password_SHA512_rounds_9000/config 24_chgpasswd_password_SHA512_rounds_9000/config/etc 24_chgpasswd_password_SHA512_rounds_9000/data 25_chgpasswd-e_no_gshadow_file 25_chgpasswd-e_no_gshadow_file/config 25_chgpasswd-e_no_gshadow_file/config/etc 25_chgpasswd-e_no_gshadow_file/data 26_chgpasswd_no_gshadow_file_invalid_group 26_chgpasswd_no_gshadow_file_invalid_group/config 26_chgpasswd_no_gshadow_file_invalid_group/config/etc 26_chgpasswd_no_gshadow_file_invalid_group/data 29_chgpasswd-e_no_gshadow_entry 29_chgpasswd-e_no_gshadow_entry/config 29_chgpasswd-e_no_gshadow_entry/config/etc 29_chgpasswd-e_no_gshadow_entry/data 30_chgpasswd_locked_group 30_chgpasswd_locked_group/config 30_chgpasswd_locked_group/config/etc 30_chgpasswd_locked_group/config/etc/default 30_chgpasswd_locked_group/data 31_chgpasswd_locked_gshadow 31_chgpasswd_locked_gshadow/config 31_chgpasswd_locked_gshadow/config/etc 31_chgpasswd_locked_gshadow/config/etc/default 31_chgpasswd_locked_gshadow/data 32_chgpasswd_invalid_group 32_chgpasswd_invalid_group/config 32_chgpasswd_invalid_group/config/etc 32_chgpasswd_invalid_group/config/etc/default 32_chgpasswd_invalid_group/data

Nicolas FRANÇOIS nekral-guest at alioth.debian.org
Sat Jul 16 15:56:21 UTC 2011


Author: nekral-guest
Date: 2011-07-16 15:56:21 +0000 (Sat, 16 Jul 2011)
New Revision: 3419

Added:
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config.txt
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/data/
   debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config.txt
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/data/
   debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config.txt
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/data/
   debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config.txt
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/data/
   debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config.txt
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/data/
   debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config.txt
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/data/
   debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config.txt
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/data/
   debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config.txt
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/data/
   debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/data/usage.out
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/data/
   debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/data/
   debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/data/
   debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/data/
   debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/data/
   debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/data/
   debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/data/
   debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/data/
   debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/data/
   debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/data/
   debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/data/
   debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/data/
   debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/data/group
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/data/
   debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/data/group
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/group
   debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/gshadow
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config.txt
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/data/
   debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/data/chgpasswd.err
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config.txt
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/data/
   debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/data/chgpasswd.err
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/chgpasswd.test
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config.txt
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/default/
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/default/useradd
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/group
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/gshadow
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/passwd
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/shadow
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/data/
   debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/data/chgpasswd.err
Log:
Added tests for chgpasswd.


Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,48 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can display its usage message"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Get chgpasswd usage (chgpasswd -h)..."
+chgpasswd -h >tmp/usage.out
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/06_chgpasswd_usage/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,11 @@
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd displays its usage message in case on non recognized option"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Get chgpasswd usage (chgpasswd --foo)..."
+chgpasswd --foo 2>tmp/usage.out && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "2"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/07_chgpasswd_usage_bad_option/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,12 @@
+chgpasswd: unrecognized option '--foo'
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks that -e and -m are not provided at the same time"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Password are encrypted and must use md5 (chgpasswd -m -e)..."
+echo 'nobody:test' | chgpasswd -m -e 2>tmp/usage.out && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "2"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/nonexistent:/bin/sh

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/08_chgpasswd_usage-e-m_exclusive/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,12 @@
+chgpasswd: the -c, -e, and -m flags are exclusive
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks that -e and -c are not provided at the same time"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Password are encrypted and must use another method (chgpasswd -c SHA512 -e)..."
+echo 'nobody:test' | chgpasswd -c SHA512 -e 2>tmp/usage.out && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "2"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/nonexistent:/bin/sh

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/09_chgpasswd_usage-e-c_exclusive/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,12 @@
+chgpasswd: the -c, -e, and -m flags are exclusive
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks that -c and -m are not provided at the same time"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Password must use md5 and another method (chgpasswd -m -c SHA256)..."
+echo 'nobody:test' | chgpasswd -m -c SHA256 2>tmp/usage.out && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "2"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/nonexistent:/bin/sh

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/10_chgpasswd_usage-m-c_exclusive/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,12 @@
+chgpasswd: the -c, -e, and -m flags are exclusive
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks that -c is provided if -s is used"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Password must use md5 and another method (chgpasswd --sha-rounds 12)..."
+echo 'nobody:test' | chgpasswd --sha-rounds 12 2>tmp/usage.out && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "2"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/nonexistent:/bin/sh

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/11_chgpasswd_usage-s_without-c/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,12 @@
+chgpasswd: -s flag is only allowed with the -c flag
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks the -s argument"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Password must use md5 and another method (chgpasswd --sha-rounds 12foo -c SHA512)..."
+echo 'nobody:test' | chgpasswd --sha-rounds 12foo -c SHA512 2>tmp/usage.out && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "2"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/nonexistent:/bin/sh

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/12_chgpasswd_usage-s_invalid/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,12 @@
+chgpasswd: invalid numeric argument '12foo'
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,54 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks the -c argument"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Password must use md5 and another method (chgpasswd --crypt-method SHA513)..."
+echo 'nobody:test' | chgpasswd --crypt-method SHA513 2>tmp/usage.out && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "2"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/usage.out
+echo "======================================================================="
+echo -n "Check the usage message..."
+diff -au data/usage.out tmp/usage.out
+echo "usage message OK."
+rm -f tmp/usage.out
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/nonexistent:/bin/sh

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config.txt
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config.txt	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/config.txt	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,10 @@
+# no testsuite password
+# root password: rootF00barbaz
+# myuser password: myuserF00barbaz
+
+user foo, in group users (only in /etc/group)
+user foo, in group tty (only in /etc/gshadow)
+user foo, in group floppy
+user foo, admin of group disk
+user foo, admin and member of group fax
+user foo, admin and member of group cdrom (only in /etc/gshadow)

Added: debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/data/usage.out
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/data/usage.out	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/13_chgpasswd_usage-c_invalid/data/usage.out	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,12 @@
+chgpasswd: unsupported crypt method: SHA513
+Usage: chgpasswd [options]
+
+Options:
+  -c, --crypt-method <METHOD>   the crypt method (one of NONE DES MD5 SHA256 SHA512)
+  -e, --encrypted               supplied passwords are encrypted
+  -h, --help                    display this help message and exit
+  -m, --md5                     encrypt the clear text password using
+                                the MD5 algorithm
+  -s, --sha-rounds              number of SHA rounds for the SHA*
+                                crypt algorithms
+

Added: debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use encrypted password"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd -e)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd -e
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/14_chgpasswd_password_encrypted/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:test2::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:test::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create md5 passwords"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --md5)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --md5
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/15_chgpasswd_password_md5/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_MD5 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_MD5 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use encrypted passwords"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd -c NONE)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd -c NONE
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/16_chgpasswd_password_NONE/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:test2::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:test::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create MD5 passwords"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method MD5)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method MD5
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/17_chgpasswd_password_MD5/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_MD5 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_MD5 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create DES passwords"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method DES)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method DES
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/18_chgpasswd_password_DES/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_DES test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_DES test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create SHA256 passwords"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method SHA256)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method SHA256
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/19_chgpasswd_password_SHA256/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_SHA256 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_SHA256 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create SHA256 passwords and use at least 1000 rounds"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method SHA256 -s 900)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method SHA256 -s 900
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+grep nogroup /etc/gshadow | grep -q ':\$5\$rounds=1000\$'
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/20_chgpasswd_password_SHA256_rounds_900/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_SHA256 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_SHA256 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create SHA256 passwords and use the requested number of rounds"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method SHA256 -s 9000)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method SHA256 -s 9000
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+grep nogroup /etc/gshadow | grep -q ':\$5\$rounds=9000\$'
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/21_chgpasswd_password_SHA256_rounds_9000/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_SHA256 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_SHA256 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create SHA512 passwords"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method SHA512)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method SHA512
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/22_chgpasswd_password_SHA512/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_SHA512 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_SHA512 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create SHA512 passwords and use at least 1000 rounds"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method SHA512 -s 900)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method SHA512 -s 900
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+grep nogroup /etc/gshadow | grep -q ':\$6\$rounds=1000\$'
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/23_chgpasswd_password_SHA512_rounds_900/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_SHA512 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_SHA512 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd can use create SHA512 passwords and use the requested number of rounds"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup and lp's password (chgpasswd --crypt-method SHA512 -s 9000)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd --crypt-method SHA512 -s 9000
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+grep nogroup /etc/gshadow | grep -q ':\$6\$rounds=9000\$'
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/24_chgpasswd_password_SHA512_rounds_9000/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:@PASS_SHA512 test2@::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:@PASS_SHA512 test@::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,44 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd changes the group file if gshadow does not exist"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Remove /etc/gshadow..."
+rm -f /etc/gshadow
+echo "OK"
+
+echo -n "Change nogroup's and lp's password..."
+echo 'nogroup:test
+lp:test2' | chgpasswd -e
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl data/group /etc/group
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check that gshadow does not exist..."
+test ! -f /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:foo:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:bar:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/data/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/data/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/25_chgpasswd-e_no_gshadow_file/data/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:test2:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:test:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,44 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd changes the group file if gshadow does not exist"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Remove /etc/gshadow..."
+rm -f /etc/gshadow
+echo "OK"
+
+echo -n "Change nogroup's and lp's password..."
+echo 'nogroup:test
+lp:test2' | chgpasswd -e
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl data/group /etc/group
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check that gshadow does not exist..."
+test ! -f /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+lp:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/data/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/data/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/26_chgpasswd_no_gshadow_file_invalid_group/data/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:test2:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:test:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd changes the group entry if there are no gshadow entries"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change nogroup's and lp's password..."
+echo 'nogroup:test
+lp:test2' | chgpasswd -e
+echo "OK"
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl data/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl data/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:x:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,19 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,18 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,41 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:
+adm:x:4:
+tty:x:5:
+disk:x:6:
+lp:test2:7:
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:

Added: debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/29_chgpasswd-e_no_gshadow_entry/data/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,40 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::
+adm:*::
+tty:*::
+disk:*::
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*::
+voice:*::
+cdrom:*::
+floppy:*::
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:test::
+crontab:x::
+Debian-exim:x::

Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,61 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks if the group file is locked"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config; rm -f /etc/group.lock' 0
+
+change_config
+
+echo -n "Create lock file for /etc/group..."
+touch /etc/group.lock
+echo "done"
+
+echo -n "Change passwords (chgpasswd -e)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd -e 2>tmp/chgpasswd.err && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+rm -f /etc/group.lock
+
+echo -n "Check returned status ($status)..."
+test "$status" = "1"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/chgpasswd.err
+echo "======================================================================="
+echo -n "Check that there were a failure message..."
+diff -au data/chgpasswd.err tmp/chgpasswd.err
+echo "error message OK."
+rm -f tmp/chgpasswd.err
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,42 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:root
+adm:x:4:root,foo
+tty:x:5:
+disk:x:6:
+lp:x:7:foo,root
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:foo
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:foo
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:foo
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:
+foo:x:1000:

Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,42 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::root
+adm:*::root,foo
+tty:*::foo
+disk:*:foo:
+lp:*::foo,root
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*:foo:foo
+voice:*::
+cdrom:*:foo:foo
+floppy:*::foo
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::
+foo:*::

Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/home/foo:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::
+foo:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/config.txt
===================================================================
Added: debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/data/chgpasswd.err
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/data/chgpasswd.err	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/30_chgpasswd_locked_group/data/chgpasswd.err	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,2 @@
+chgpasswd: existing lock file /etc/group.lock without a PID
+chgpasswd: cannot lock /etc/group; try again later.

Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,61 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks if the gshadow file is locked"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config; rm -f /etc/gshadow.lock' 0
+
+change_config
+
+echo -n "Create lock file for /etc/gshadow..."
+touch /etc/gshadow.lock
+echo "done"
+
+echo -n "Change passwords (chgpasswd -e)..."
+echo 'nogroup:test
+lp:test2' | chgpasswd -e 2>tmp/chgpasswd.err && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+rm -f /etc/gshadow.lock
+
+echo -n "Check returned status ($status)..."
+test "$status" = "1"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/chgpasswd.err
+echo "======================================================================="
+echo -n "Check that there were a failure message..."
+diff -au data/chgpasswd.err tmp/chgpasswd.err
+echo "error message OK."
+rm -f tmp/chgpasswd.err
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,42 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:root
+adm:x:4:root,foo
+tty:x:5:
+disk:x:6:
+lp:x:7:foo,root
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:foo
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:foo
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:foo
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:
+foo:x:1000:

Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,42 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::root
+adm:*::root,foo
+tty:*::foo
+disk:*:foo:
+lp:*::foo,root
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*:foo:foo
+voice:*::
+cdrom:*:foo:foo
+floppy:*::foo
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::
+foo:*::

Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/home/foo:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::
+foo:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/config.txt
===================================================================
Added: debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/data/chgpasswd.err
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/data/chgpasswd.err	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/31_chgpasswd_locked_gshadow/data/chgpasswd.err	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,2 @@
+chgpasswd: existing lock file /etc/gshadow.lock without a PID
+chgpasswd: cannot lock /etc/gshadow; try again later.

Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/chgpasswd.test
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/chgpasswd.test	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/chgpasswd.test	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,56 @@
+#!/bin/sh
+
+set -e
+
+cd $(dirname $0)
+
+. ../../../common/config.sh
+. ../../../common/log.sh
+
+log_start "$0" "chgpasswd checks that users exist"
+
+save_config
+
+# restore the files on exit
+trap 'log_status "$0" "FAILURE"; restore_config' 0
+
+change_config
+
+echo -n "Change passwords (chgpasswd)..."
+echo 'nogroup:test
+bar:bar2
+lp:test2' | chgpasswd 2>tmp/chgpasswd.err && exit 1 || {
+	status=$?
+}
+echo "OK"
+
+echo -n "Check returned status ($status)..."
+test "$status" = "1"
+echo "OK"
+
+echo "chgpasswd reported:"
+echo "======================================================================="
+cat tmp/chgpasswd.err
+echo "======================================================================="
+echo -n "Check that there were a failure message..."
+diff -au data/chgpasswd.err tmp/chgpasswd.err
+echo "error message OK."
+rm -f tmp/chgpasswd.err
+
+echo -n "Check the passwd file..."
+../../../common/compare_file.pl config/etc/passwd /etc/passwd
+echo "OK"
+echo -n "Check the group file..."
+../../../common/compare_file.pl config/etc/group /etc/group
+echo "OK"
+echo -n "Check the shadow file..."
+../../../common/compare_file.pl config/etc/shadow /etc/shadow
+echo "OK"
+echo -n "Check the gshadow file..."
+../../../common/compare_file.pl config/etc/gshadow /etc/gshadow
+echo "OK"
+
+log_status "$0" "SUCCESS"
+restore_config
+trap '' 0
+


Property changes on: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/chgpasswd.test
___________________________________________________________________
Added: svn:executable
   + *

Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/default/useradd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/default/useradd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/default/useradd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,36 @@
+# Default values for useradd(8)
+#
+# The SHELL variable specifies the default login shell on your
+# system.
+# Similar to DHSELL in adduser. However, we use "sh" here because
+# useradd is a low level utility and should be as general
+# as possible
+SHELL=/bin/foobar
+#
+# The default group for users
+# 100=users on Debian systems
+# Same as USERS_GID in adduser
+# This argument is used when the -n flag is specified.
+# The default behavior (when -n and -g are not specified) is to create a
+# primary user group with the same name as the user being added to the
+# system.
+GROUP=10
+#
+# The default home directory. Same as DHOME for adduser
+HOME=/tmp
+#
+# The number of days after a password expires until the account 
+# is permanently disabled
+INACTIVE=12
+#
+# The default expire date
+EXPIRE=2007-12-02
+#
+# The SKEL variable specifies the directory containing "skeletal" user
+# files; in other words, files such as a sample .profile that will be
+# copied to the new user's home directory when it is created.
+# SKEL=/etc/skel
+#
+# Defines whether the mail spool should be created while
+# creating the account
+# CREATE_MAIL_SPOOL=yes

Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/group
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/group	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/group	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,42 @@
+root:x:0:
+daemon:x:1:
+bin:x:2:
+sys:x:3:root
+adm:x:4:root,foo
+tty:x:5:
+disk:x:6:
+lp:x:7:foo,root
+mail:x:8:
+news:x:9:
+uucp:x:10:
+man:x:12:
+proxy:x:13:
+kmem:x:15:
+dialout:x:20:
+fax:x:21:foo
+voice:x:22:
+cdrom:x:24:
+floppy:x:25:foo
+tape:x:26:
+sudo:x:27:
+audio:x:29:
+dip:x:30:
+www-data:x:33:
+backup:x:34:
+operator:x:37:
+list:x:38:
+irc:x:39:
+src:x:40:
+gnats:x:41:
+shadow:x:42:
+utmp:x:43:
+video:x:44:
+sasl:x:45:
+plugdev:x:46:
+staff:x:50:
+games:x:60:
+users:x:100:foo
+nogroup:x:65534:
+crontab:x:101:
+Debian-exim:x:102:
+foo:x:1000:

Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/gshadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/gshadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/gshadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,42 @@
+root:*::
+daemon:*::
+bin:*::
+sys:*::root
+adm:*::root,foo
+tty:*::foo
+disk:*:foo:
+lp:*::foo,root
+mail:*::
+news:*::
+uucp:*::
+man:*::
+proxy:*::
+kmem:*::
+dialout:*::
+fax:*:foo:foo
+voice:*::
+cdrom:*:foo:foo
+floppy:*::foo
+tape:*::
+sudo:*::
+audio:*::
+dip:*::
+www-data:*::
+backup:*::
+operator:*::
+list:*::
+irc:*::
+src:*::
+gnats:*::
+shadow:*::
+utmp:*::
+video:*::
+sasl:*::
+plugdev:*::
+staff:*::
+games:*::
+users:*::
+nogroup:*::
+crontab:x::
+Debian-exim:x::
+foo:*::

Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/passwd
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/passwd	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/passwd	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:x:0:0:root:/root:/bin/bash
+daemon:x:1:1:daemon:/usr/sbin:/bin/sh
+bin:x:2:2:bin:/bin:/bin/sh
+sys:x:3:3:sys:/dev:/bin/sh
+sync:x:4:65534:sync:/bin:/bin/sync
+games:x:5:60:games:/usr/games:/bin/sh
+man:x:6:12:man:/var/cache/man:/bin/sh
+lp:x:7:7:lp:/var/spool/lpd:/bin/sh
+mail:x:8:8:mail:/var/mail:/bin/sh
+news:x:9:9:news:/var/spool/news:/bin/sh
+uucp:x:10:10:uucp:/var/spool/uucp:/bin/sh
+proxy:x:13:13:proxy:/bin:/bin/sh
+www-data:x:33:33:www-data:/var/www:/bin/sh
+backup:x:34:34:backup:/var/backups:/bin/sh
+list:x:38:38:Mailing List Manager:/var/list:/bin/sh
+irc:x:39:39:ircd:/var/run/ircd:/bin/sh
+gnats:x:41:41:Gnats Bug-Reporting System (admin):/var/lib/gnats:/bin/sh
+nobody:x:65534:65534:nobody:/nonexistent:/bin/sh
+Debian-exim:x:102:102::/var/spool/exim4:/bin/false
+foo:x:1000:1000::/home/foo:/bin/false

Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/shadow
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/shadow	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config/etc/shadow	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,20 @@
+root:$1$NBLBLIXb$WUgojj1bNuxWEADQGt1m9.:12991:0:99999:7:::
+daemon:*:12977:0:99999:7:::
+bin:*:12977:0:99999:7:::
+sys:*:12977:0:99999:7:::
+sync:*:12977:0:99999:7:::
+games:*:12977:0:99999:7:::
+man:*:12977:0:99999:7:::
+lp:*:12977:0:99999:7:::
+mail:*:12977:0:99999:7:::
+news:*:12977:0:99999:7:::
+uucp:*:12977:0:99999:7:::
+proxy:*:12977:0:99999:7:::
+www-data:*:12977:0:99999:7:::
+backup:*:12977:0:99999:7:::
+list:*:12977:0:99999:7:::
+irc:*:12977:0:99999:7:::
+gnats:*:12977:0:99999:7:::
+nobody:*:12977:0:99999:7:::
+Debian-exim:!:12977:0:99999:7:::
+foo:!:12977:0:99999:7:::

Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/config.txt
===================================================================
Added: debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/data/chgpasswd.err
===================================================================
--- debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/data/chgpasswd.err	                        (rev 0)
+++ debian/trunk/tests/grouptools/chgpasswd/32_chgpasswd_invalid_group/data/chgpasswd.err	2011-07-16 15:56:21 UTC (rev 3419)
@@ -0,0 +1,2 @@
+chgpasswd: line 2: group 'bar' does not exist
+chgpasswd: error detected, changes ignored




More information about the Pkg-shadow-commits mailing list