2021-06-17 12:25:33 +02:00
<? I18N znc-sasl ?>
2021-06-15 16:15:14 +02:00
<? INC Header.tmpl ?>
<div class="container col-md-10 col-md-offset-1">
<div class="panel panel-default">
2021-06-17 12:25:33 +02:00
<div class="panel-heading"><? FORMAT "SASL" ?></div>
<form class="form-horizontal" action="<? VAR URIPrefix TOP ?><? VAR ModPath TOP ?>" method="post">
<div class="panel-body">
2021-06-15 16:15:14 +02:00
<? INC _csrf_check.tmpl ?>
2021-06-17 12:25:33 +02:00
<div class="form-group">
<label for="inputSASLUsername" class="col-sm-2 control-label"><? FORMAT "Username:" ?></label>
2021-06-15 16:15:14 +02:00
<div class="col-sm-10">
2021-06-17 12:25:33 +02:00
<input type="text" class="form-control" id="inputSASLUsername" name="username" maxlength="128" placeholder="<? FORMAT "Please enter a username." ?>">
2021-06-15 16:15:14 +02:00
</div>
2021-06-17 12:25:33 +02:00
</div>
2021-06-15 16:15:14 +02:00
2021-06-17 12:25:33 +02:00
<div class="form-group">
<label for="inputSASLPassword" class="col-sm-2 control-label"><? FORMAT "Password:" ?></label>
2021-06-15 16:15:14 +02:00
<div class="col-sm-10">
2021-06-17 12:25:33 +02:00
<input type="text" class="form-control" id="inputSASLPassword" name="username" placeholder="<? FORMAT "Please enter a password." ?>" autocomplete="off">
2021-06-15 16:15:14 +02:00
</div>
2021-06-17 12:25:33 +02:00
</div>
2021-06-15 16:15:14 +02:00
2021-06-17 12:25:33 +02:00
<div class="form-group">
<label for="inputSASLUsername" class="col-sm-2 control-label"><? FORMAT "Options" ?></label>
2021-06-15 16:15:14 +02:00
<div class="col-sm-10">
<div class="switch">
<input type="checkbox" name="require_auth" id="opt_require_auth" class="cmn-toggle cmn-toggle-round-flat" value="1"<? IF RequireAuth ?> checked="checked"<? ENDIF ?> />
<label for="opt_require_auth"></label>
2021-06-17 12:25:33 +02:00
<span class="help-block"><? FORMAT "Connect only if SASL authentication succeeds." ?></span>
2021-06-15 16:15:14 +02:00
</div>
</div>
2021-06-17 12:25:33 +02:00
</div>
2021-06-15 16:15:14 +02:00
2021-06-17 12:25:33 +02:00
<div class="form-group">
<label for="inputMechanismsDescription" class="col-sm-2 control-label"><? FORMAT "Mechanisms" ?></label>
<div class="col-sm-10">
<table class="data">
<thead>
<tr>
<th><? FORMAT "Name" ?></th>
<th><? FORMAT "Description" ?></th>
</tr>
</thead>
<tbody>
<? LOOP MechanismLoop SORTASC=Name ?>
<tr class="<? IF __EVEN__ ?>evenrow<? ELSE ?>oddrow<? ENDIF ?>">
<td><? VAR Name ?></td>
<td><? VAR Description ?></td>
</tr>
<? ENDLOOP ?>
</tbody>
</table>
</div>
<label for="inputMechanisms" class="col-sm-2 control-label"><? FORMAT "Selected mechanisms and their order:" ?></label>
<div class="col-sm-10">
<input type="text" class="form-control" id="inputMechanisms" name="mechanisms" value="<? VAR Mechanisms ?>">
<script>
$(" #inputMechanisms " ).selectize( {
plugins: ["drag_drop"],
delimiter: " ",
options: [<? LOOP MechanismLoop SORTASC=Name ?>{value:"<? VAR Name ?>",text:"<? VAR Name ?>"},<? ENDLOOP ?>],
});
</script>
</div>
</div>
<div class="panel-footer text-right">
<input class="btn btn-danger" type="reset" value="Reset">
<input class="btn btn-success" type="submit" name="save" value="<? FORMAT "Save" ?>" />
</div>
</form>
2021-06-15 16:15:14 +02:00
</div>
</div>
<? INC Footer.tmpl ?>