Merge lp:~mterry/user-setup/only-ascii-passwords into lp:~ubuntu-core-dev/user-setup/ubuntu

Proposed by Michael Terry
Status: Needs review
Proposed branch: lp:~mterry/user-setup/only-ascii-passwords
Merge into: lp:~ubuntu-core-dev/user-setup/ubuntu
Diff against target: 98 lines (+45/-1)
5 files modified
debian/changelog (+7/-0)
debian/po/templates.pot (+14/-1)
debian/user-setup-udeb.templates (+6/-0)
functions.sh (+9/-0)
user-setup-ask (+9/-0)
To merge this branch: bzr merge lp:~mterry/user-setup/only-ascii-passwords
Reviewer Review Type Date Requested Status
Colin Watson Needs Information
Review via email: mp+41753@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Colin Watson (cjwatson) wrote :

Thanks for the branch. Can we send this to Debian instead, with
appropriate justification? Translation changes are expensive to
maintain locally in Ubuntu, and I would like to only do it when it's
absolutely necessary.

Before we merge this, I think comments 8 and 9 from the linked bug
report need to be addressed with specific information on things that go
wrong with non-ASCII passwords.

 review needs-info

review: Needs Information

Unmerged revisions

228. By Michael Terry

Don't allow user to enter a non-ascii character in oem-config's password
fields (LP: #495695)

227. By Colin Watson

releasing version 1.28ubuntu10

226. By Colin Watson

Fix syntax error introduced in 1.28ubuntu9.

225. By Oliver Grawert

adjust the dd command for zeroing out swapfiles

224. By Oliver Grawert

releasing version 1.28ubuntu9

223. By Oliver Grawert

make zeroing swap work also with swapfiles if encrypted home is selected Bug #646421

222. By Oliver Grawert

merge 16M blocksize for swap zeroing change from the package LP: #432422

221. By Evan

releasing version 1.28ubuntu7

220. By Evan

Allow forcing the encrypted home option (LP: #566552).

219. By Colin Watson

releasing version 1.28ubuntu6

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2010-10-04 11:41:38 +0000
3+++ debian/changelog 2010-11-24 15:56:22 +0000
4@@ -1,3 +1,10 @@
5+user-setup (1.28ubuntu11) natty; urgency=low
6+
7+ * Don't allow user to enter a non-ascii character in oem-config's password
8+ fields (LP: #495695)
9+
10+ -- Debbie Beliveau <debbie.beliveau@canonical.com> Wed, 24 Nov 2010 10:51:41 -0500
11+
12 user-setup (1.28ubuntu10) maverick; urgency=low
13
14 * Fix syntax error introduced in 1.28ubuntu9.
15
16=== modified file 'debian/po/templates.pot'
17--- debian/po/templates.pot 2009-07-03 12:47:44 +0000
18+++ debian/po/templates.pot 2010-11-24 15:56:22 +0000
19@@ -8,7 +8,7 @@
20 msgstr ""
21 "Project-Id-Version: PACKAGE VERSION\n"
22 "Report-Msgid-Bugs-To: user-setup@packages.debian.org\n"
23-"POT-Creation-Date: 2009-07-03 13:45+0100\n"
24+"POT-Creation-Date: 2009-12-10 17:31-0500\n"
25 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
26 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
27 "Language-Team: LANGUAGE <LL@li.org>\n"
28@@ -347,3 +347,16 @@
29 #: ../user-setup-udeb.templates:22001
30 msgid "Check /var/log/syslog or see virtual console 4 for the details."
31 msgstr ""
32+
33+#. Type: error
34+#. Description
35+#: ../user-setup-udeb.templates:23001
36+msgid "Password input error"
37+msgstr ""
38+
39+#. Type: error
40+#. Description
41+#: ../user-setup-udeb.templates:23001
42+msgid "Invalid character in password. Please try again."
43+msgstr ""
44+
45
46=== modified file 'debian/user-setup-udeb.templates'
47--- debian/user-setup-udeb.templates 2010-04-19 16:59:35 +0000
48+++ debian/user-setup-udeb.templates 2010-11-24 15:56:22 +0000
49@@ -205,6 +205,12 @@
50 Default: false
51 Description: for internal use only
52
53+# Error when non-ascii character is included in password
54+Template: user-setup/password-not-ascii
55+Type: error
56+_Description: Password input error
57+ Invalid character in password. Please try again.
58+
59 Template: user-setup/progress/wipe-swap
60 Type: text
61 _Description: Wiping swap space for security (this may take a while)...
62
63=== modified file 'functions.sh'
64--- functions.sh 2009-06-03 14:17:53 +0000
65+++ functions.sh 2010-11-24 15:56:22 +0000
66@@ -65,3 +65,12 @@
67 fi
68 [ "$(printf %s "$1" | wc -c)" -lt 8 ]
69 }
70+
71+password_is_not_ascii () {
72+ if LC_ALL=C expr "$1" : '[[:graph:]]*$' >/dev/null; then
73+ return 1 # Password all ascii characters
74+ fi
75+
76+ return 0
77+}
78+
79
80=== modified file 'user-setup-ask'
81--- user-setup-ask 2010-04-19 16:59:35 +0000
82+++ user-setup-ask 2010-11-24 15:56:22 +0000
83@@ -209,6 +209,15 @@
84 db_fset passwd/user-password-again seen false
85 STATE=6
86 continue
87+ elif [ "$USER_PW" ] && password_is_not_ascii "$USER_PW"; then
88+ db_set passwd/user-password ""
89+ db_set passwd/user-password-again ""
90+ db_fset user-setup/password-not-ascii seen false
91+ db_input critical user-setup/password-not-ascii
92+ db_fset passwd/user-password seen false
93+ db_fset passwd/user-password-again seen false
94+ STATE=6
95+ continue
96 elif [ "$USER_PW" ] && password_is_weak "$USER_PW"; then
97 db_set user-setup/password-weak false
98 db_fset user-setup/password-weak seen false

Subscribers

People subscribed via source and target branches

to all changes: