blob: 5fbfe65425bbe9bef8617fe6de060f34e7e2d0f4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
|
<html>
<head>
<title>dump.fm Password Reset</title>
<script type="text/javascript" src="/static/js/sha1.js"></script>
$head()$
<script>
jQuery(function() {
jQuery("#submit").click(function() {
var p1 = jQuery('#p1').val();
var p2 = jQuery('#p1').val();
if (p1.length < 5) {
jQuery('#feedback').text("Password must be at least five letters long!").show();
jQuery('#p1, #p2').val("");
return false;
} else if (p1 != p2) {
jQuery('#feedback').text("Both passwords must match!").show();
jQuery('#p1, #p2').val("");
return false;
}
var nick = '$nick$';
var hash = hex_sha1(nick + '\$' + p1 + '\$dumpfm');
jQuery('#hash').val(hash);
return true;
});
});
</script>
</head>
<link rel="stylesheet" type="text/css" href="static/css/index.css">
<body>
<div id="rapper"></div>
<div id="content" style="z-index:77;">
<div id="main" align="center">
<div id="passwordreset">
<div id="logo-and-text">
<a href="/"><img src="/static/img/dumpclearlogo2.png"></a>
<div align="center">
$if(valid_request)$
<div id="feedback" style="display: none; color: red; margin-bottom: 2em;"></div>
<h1>Reset Your Password</h1>
<br>
<label style="text-align:left;margin-bottom:-8px;">New Password:</label>
<input type="password" id="p1">
<br>
<label style="text-align:left;margin-bottom:-8px;">Repeat Password:</label>
<input type="password" id="p2">
<br>
<form action="$link$" method="POST">
<input type="hidden" value="hash" name="hash" id="hash">
<input type="submit" value="Change password" id="submit">
</form>
$else$
<h1>Bad Request</h1>
<span>Your password reset link is invalid or has expired. Please try
resetting again.</span>
$endif$
</div></div></div></div>
</body>
</html>
|