Subversion Repositories ALCASAR

Rev

Rev 2850 | Rev 3139 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log

Rev 2850 Rev 3026
Line 1... Line 1...
1
<?php
1
<?php
2
# $Id: password.php 2850 2020-07-15 22:24:44Z rexy $
2
# $Id: password.php 3026 2022-06-30 21:53:54Z rexy $
3
#
3
#
4
# change user password on ALCASAR
4
# change user password on ALCASAR
5
# by ANGEL95 & REXY
5
# by ANGEL95 & REXY
6
 
6
 
7
/****************************************************************
7
/****************************************************************
Line 45... Line 45...
45
	exit(); }
45
	exit(); }
46
}
46
}
47
 
47
 
48
require('/etc/freeradius-web/config.php');
48
require('/etc/freeradius-web/config.php');
49
 
49
 
-
 
50
$page = "password";
50
$current_page = htmlspecialchars($_SERVER['PHP_SELF']);
51
$current_page = htmlspecialchars($_SERVER['PHP_SELF']);
51
$homepage = (((!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off')) ? 'https' : 'http').'://'.$conf['HOSTNAME'].'.'.$conf['DOMAIN'];
52
$homepage = (((!empty($_SERVER['HTTPS']) && $_SERVER['HTTPS'] !== 'off')) ? 'https' : 'http').'://'.$conf['HOSTNAME'].'.'.$conf['DOMAIN'];
52
 
53
 
53
// Choice of language
54
// Choice of language
54
$Language = 'en';
55
$Language = 'en';
Line 205... Line 206...
205
	<link rel="icon" href="/images/favicon-48.ico" type="image/ico">
206
	<link rel="icon" href="/images/favicon-48.ico" type="image/ico">
206
 
207
 
207
	<script src="/js/pwdmeter.js"></script>
208
	<script src="/js/pwdmeter.js"></script>
208
</head>
209
</head>
209
<body>
210
<body>
210
	<div class="col-xs-12 col-md-10 col-md-offset-1"> 
211
	<div class="col-12 col-lg-10 offset-lg-1">
211
		<!-- HeaderBox -->
-
 
212
		<div class="row banner">
-
 
213
			<!-- Logo box -->
-
 
214
			<div class="hidden-xs col-sm-3 col-md-2 col-lg-2"> 
-
 
215
				<img class="img-responsive img-organisme" src="images/organisme.png">
-
 
216
			</div>
212
 
217
			<!-- Title -->
-
 
218
			<div id="cadre_titre" class="titre_banner col-xs-12 col-sm-8">
-
 
219
				<div class="row">
-
 
220
					<p id="acces_controle" class="titre_controle"><?= $l_title ?></p>
-
 
221
				</div>
-
 
222
				<div class="row">
-
 
223
				<?php if (isset($changePasswordMessage)): ?>
213
		<?php require_once(__DIR__.'/header.php'); ?>
224
					<?= $changePasswordMessage ?>
-
 
225
				<?php endif; ?>
-
 
226
				</div>
-
 
227
			</div>
-
 
228
			<!-- Logo box -->
-
 
229
			<div class="img_banner hidden-xs col-sm-3 col-md-2 col-lg-2">
-
 
230
				<img class="img-responsive img-organisme" src="images/logo-alcasar_70.png">
-
 
231
			</div>
-
 
232
		</div>
-
 
233
 
214
 
234
		<!-- Main content box -->
215
		<!-- Main content box -->
235
		<div class="row">
216
		<div class="row">
236
			<form name="master" id="contenu_acces" action="<?= $current_page ?>" method="post" class="col-xs-12 col-sm-12 col-md-offset-1 col-md-10">
217
			<form name="master" id="contenu_acces" action="<?= $current_page ?>" method="post" class="col-12 offset-lg-1 col-lg-10">
237
				<input class="row" type="hidden" name="action" value="checkpass">
218
				<input class="row" type="hidden" name="action" value="checkpass">
238
 
219
 
239
				<div class="row input_row">
220
				<div class="row input_row">
240
					<div class="label_name col-xs-3 col-sm-3 col-md-4"><?= $l_form_l1 ?></div>
221
					<div class="label_name col-3 col-lg-4"><?= $l_form_l1 ?></div>
241
					<div class="col-xs-6 col-sm-6 col-md-4">
222
					<div class="col-6 col-lg-4">
242
						<input type="text" name="login" class="form-control" id="input_value" value="" label="test">
223
						<input type="text" name="login" class="form-control" id="input_value" value="" label="test">
243
					</div>
224
					</div>
244
				</div>
225
				</div>
245
 
226
 
246
				<div class="row input_row">
227
				<div class="row input_row">
247
					<div class="label_name col-xs-3 col-sm-3 col-md-4"><?= $l_form_l2 ?></div>
228
					<div class="label_name col-3 col-lg-4"><?= $l_form_l2 ?></div>
248
					<div class="col-xs-6 col-sm-6 col-md-4">
229
					<div class="col-6 col-lg-4">
249
						<input type="password" class="form-control" id="input_value" name="passwd" value="">
230
						<input type="password" class="form-control" id="input_value" name="passwd" value="">
250
					</div>
231
					</div>
251
				</div>
232
				</div>
252
 
233
 
253
				<div class="row input_row">
234
				<div class="row input_row">
254
					<div class="label_name col-xs-3 col-sm-3 col-md-4"><?= $l_form_l3 ?></div>
235
					<div class="label_name col-3 col-lg-4"><?= $l_form_l3 ?></div>
255
					<div class="col-xs-6 col-sm-6 col-md-4">
236
					<div class="col-6 col-lg-4">
256
						<input class="form-control" id="input_value" type="password" name="newpasswd" value="" autocomplete="off" onkeyup="chkPass(this.value);" />
237
						<input class="form-control" id="input_value" type="password" name="newpasswd" value="" autocomplete="off" onkeyup="chkPass(this.value);" />
257
					</div>
238
					</div>
258
					<div class="col-xs-3 col-sm-3 col-md-4">	
239
					<div class="col-3 col-lg-4">	
259
						<input type="text" id="passwordTxt" name="passwordTxt" autocomplete="off" onkeyup="chkPass(this.value);" class="hide" />
240
						<input type="text" id="passwordTxt" name="passwordTxt" autocomplete="off" onkeyup="chkPass(this.value);" class="hide" />
260
					</div>
241
					</div>
261
				</div>
242
				</div>
262
		
243
		
263
				<div class="row input_row">
244
				<div class="row input_row">
264
					
245
					
265
					<div class="label_name col-xs-3 col-sm-3 col-md-4"><?= $l_eval_pass ?></div>
246
					<div class="label_name col-3 col-lg-4"><?= $l_eval_pass ?></div>
266
					<div class="col-xs-6 col-sm-6 col-md-4">
247
					<div class="col-6 col-lg-4">
267
						<div class="row scorebarDisplay">
248
						<div class="progress bg-secondary">
268
							<div id="scorebarBorder" class="col-xs-12 col-sm-12">
-
 
269
								<div id="score" class="row">0%</div>
-
 
270
								<div id="scorebar" class="row">&nbsp;</div>
249
  							<div id ="pwprogress" class="progress-bar" role="progressbar" style="width: 0%;">0%</div>
271
							</div>
-
 
272
						</div>
250
						</div>
273
						<div class="row">
251
						<div class="row">
274
							<div id="lien_pass" class="col-xs-12 col-sm-12"><?= $l_passwordmeter ?></div>
252
							<div id="lien_pass" class="col-12"><?= $l_passwordmeter ?></div>
275
						</div>
253
						</div>
276
					</div>
254
					</div>
277
				</div>
255
				</div>
278
 
256
 
279
				<div class="row input_row">
257
				<div class="row input_row">
280
					<div class="label_name col-xs-3 col-sm-3 col-md-4"><?= $l_form_l4 ?></div>
258
					<div class="label_name col-3 col-lg-4"><?= $l_form_l4 ?></div>
281
					<div class="col-xs-6 col-sm-6 col-md-4">
259
					<div class="col-6 col-lg-4">
282
						<input type="password" class="form-control" id="input_value" name="newpasswd2" value="">
260
						<input type="password" class="form-control" id="input_value" name="newpasswd2" value="">
283
					</div>
261
					</div>
284
				</div>
262
				</div>
285
	
263
	
286
				<div class="row input_row">
264
				<div class="row input_row">
287
					<div class="col-xs-5 col-xs-offset-1 col-sm-4 col-sm-offset-2">
265
					<div class="col-5 offset-sm-1 col-md-4 offset-md-2">
288
						<input id="buttons" class="btn btn-default" value="<?= $l_form_button_retour ?>" onclick="window.location.href = '<?= $homepage ?>';">
266
						<input id="buttons" class="btn btn-default" value="<?= $l_form_button_retour ?>" onclick="window.location.href = '<?= $homepage ?>';">
289
					</div>
267
					</div>
290
					<div class="col-xs-5 col-sm-4">
268
					<div class="col-5 col-md-4">
291
						<button type="submit" class="btn btn-primary" id="buttons"><?= $l_form_button_valid ?></button>
269
						<button type="submit" class="btn btn-primary" id="buttons"><?= $l_form_button_valid ?></button>
292
					</div>
270
					</div>
293
				</div>
271
				</div>
294
			</form>
272
			</form>
295
			</div>
273
			</div>
296
<!--			
274
<!--			
297
			<div class="row">
275
			<div class="row">
298
				<div id="boite_logo" class="img_banner col-xs-12 hidden-sm hidden-md hidden-lg">
276
				<div id="boite_logo" class="img_banner col-xs-12 hidden-sm hidden-md hidden-lg">
299
					<img class="img-responsive image" src="images/organisme.png">
277
					<img class="img-fluid image" src="images/organisme.png">
300
				</div>
278
				</div>
301
			</div> -->
279
			</div> -->
302
		</div>
280
		</div>
303
		<div id="info_pass">
281
		<div id="info_pass">
304
			<table id="tablePwdStatus" cellpadding="5" cellspacing="1" border="0">
282
			<table id="tablePwdStatus" cellpadding="5" cellspacing="1" border="0">