Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
bugzilla
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
bugzilla
Commits
1d971ce0
Commit
1d971ce0
authored
Aug 19, 1999
by
terry%mozilla.org
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Patch by Chris Baldwin <chris.baldwin@siara.com> -- allow optional
entry of the user's realname. Note that nothing actually makes use of this info at present.
parent
63dd4a06
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
31 additions
and
9 deletions
+31
-9
CGI.pl
CGI.pl
+1
-1
changepassword.cgi
changepassword.cgi
+17
-3
createaccount.cgi
createaccount.cgi
+8
-2
globals.pl
globals.pl
+5
-3
No files found.
CGI.pl
View file @
1d971ce0
...
...
@@ -385,7 +385,7 @@ sub confirm_login {
if
(
defined
$::FORM
{
"PleaseMailAPassword"
})
{
my
$realpwd
;
if
(
$realcryptpwd
eq
""
)
{
$realpwd
=
InsertNewUser
(
$enteredlogin
);
$realpwd
=
InsertNewUser
(
$enteredlogin
,
""
);
}
else
{
SendSQL
(
"select password from profiles where login_name = "
.
SqlQuote
(
$enteredlogin
));
...
...
changepassword.cgi
View file @
1d971ce0
...
...
@@ -33,9 +33,11 @@ if (! defined $::FORM{'pwd1'}) {
if
(
Param
(
'useqacontact'
))
{
$qacontactpart
=
", the current QA Contact"
;
}
SendSQL
(
"select emailnotification from profiles where login_name = "
.
SqlQuote
(
$::COOKIE
{
'Bugzilla_login'
}));
my
(
$emailnotification
)
=
(
FetchSQLData
());
my
$loginname
=
SqlQuote
(
$::COOKIE
{
'Bugzilla_login'
});
SendSQL
(
"select emailnotification,realname from profiles where login_name = "
.
$loginname
);
my
(
$emailnotification
,
$realname
)
=
(
FetchSQLData
());
$realname
=
value_quote
(
$realname
);
print
qq{
<form method=post>
<hr>
...
...
@@ -47,6 +49,11 @@ if (! defined $::FORM{'pwd1'}) {
<tr>
<td align=right>Re-enter your new password:</td>
<td><input type=password name="pwd2"></td>
</tr>
<tr>
<td align=right>Your real name (optional):</td>
<td><input size=35 name=realname value="$realname"></td>
</tr>
</table>
<hr>
<table>
...
...
@@ -122,6 +129,13 @@ Please click <b>Back</b> and try again.\n";
SendSQL
(
"update profiles set emailnotification='$::FORM{'emailnotification'}' where login_name = "
.
SqlQuote
(
$::COOKIE
{
'Bugzilla_login'
}));
my
$newrealname
=
$::FORM
{
'realname'
};
if
(
$newrealname
ne
""
)
{
$newrealname
=
SqlQuote
(
$newrealname
);
SendSQL
(
"update profiles set realname=$newrealname where login_name = "
.
SqlQuote
(
$::COOKIE
{
'Bugzilla_login'
}));
}
PutHeader
(
"Preferences updated."
);
print
"
...
...
createaccount.cgi
View file @
1d971ce0
...
...
@@ -44,6 +44,7 @@ Content-type: text/html
PutHeader
(
"Create a new bugzilla account"
);
my
$login
=
$::FORM
{
'login'
};
my
$realname
=
$::FORM
{
'realname'
};
if
(
defined
$login
)
{
CheckEmailSyntax
(
$login
);
if
(
DBname_to_id
(
$login
)
!=
0
)
{
...
...
@@ -53,7 +54,7 @@ if (defined $login) {
print
"the <b>E-mail me a password</b> button.\n"
;
exit
;
}
my
$password
=
InsertNewUser
(
$login
);
my
$password
=
InsertNewUser
(
$login
,
$realname
);
MailPassword
(
$login
,
$password
);
print
"A bugzilla account for <tt>$login</tt> has been created. The\n"
;
print
"password has been e-mailed to that address. When it is\n"
;
...
...
@@ -66,7 +67,8 @@ if (defined $login) {
print
q{
To create a bugzilla account, all that you need to do is to enter a
legitimate e-mail address. The account will be created, and its
password will be mailed to you.
password will be mailed to you. Optionally you may enter your real name
as well.
<FORM method=get>
<table>
...
...
@@ -74,6 +76,10 @@ password will be mailed to you.
<td align=right><b>E-mail address:</b></td>
<td><input size=35 name=login></td>
</tr>
<tr>
<td align=right><b>Real name:</b></td>
<td><input size=35 name=realname></td>
</tr>
</table>
<input type=submit>
}
;
...
...
globals.pl
View file @
1d971ce0
...
...
@@ -353,7 +353,7 @@ sub GetVersionTable {
sub
InsertNewUser
{
my
(
$username
)
=
(
@_
);
my
(
$username
,
$realname
)
=
(
@_
);
my
$password
=
""
;
for
(
my
$i
=
0
;
$i
<
8
;
$i
++
)
{
$password
.=
substr
(
"abcdefghijklmnopqrstuvwxyz"
,
int
(
rand
(
26
)),
1
);
...
...
@@ -370,7 +370,9 @@ sub InsertNewUser {
}
}
SendSQL
(
"insert into profiles (login_name, password, cryptpassword, groupset) values (@{[SqlQuote($username)]}, '$password', encrypt('$password'), $groupset)"
);
$username
=
SqlQuote
(
$username
);
$realname
=
SqlQuote
(
$realname
);
SendSQL
(
"insert into profiles (login_name, realname, password, cryptpassword, groupset) values ($username, $realname, '$password', encrypt('$password'), $groupset)"
);
return
$password
;
}
...
...
@@ -406,7 +408,7 @@ sub DBNameToIdAndCheck {
return
$result
;
}
if
(
$forceok
)
{
InsertNewUser
(
$name
);
InsertNewUser
(
$name
,
""
);
$result
=
DBname_to_id
(
$name
);
if
(
$result
>
0
)
{
return
$result
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment