[Web] Skip passwords in API log
parent
0019502069
commit
7701660119
|
@ -40,7 +40,7 @@ $tfa_data = get_tfa();
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<div class="col-sm-offset-3 col-sm-9">
|
<div class="col-sm-offset-3 col-sm-9">
|
||||||
<button class="btn btn-default" id="edit_selected" data-id="admin" data-item="null" data-api-url='edit/self' data-api-attr='{}' href="#"><span class="glyphicon glyphicon-check"></span> <?=$lang['admin']['save'];?></button>
|
<button class="btn btn-default" id="edit_selected" data-id="admin" data-item="admin" data-api-url='edit/self' data-api-attr='{}' href="#"><span class="glyphicon glyphicon-check"></span> <?=$lang['admin']['save'];?></button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
@ -522,7 +522,7 @@ $tfa_data = get_tfa();
|
||||||
<label for="help_text"><?=$lang['admin']['help_text'];?>:</label>
|
<label for="help_text"><?=$lang['admin']['help_text'];?>:</label>
|
||||||
<textarea class="form-control" id="help_text" name="help_text" rows="7"><?=$ui_texts['help_text'];?></textarea>
|
<textarea class="form-control" id="help_text" name="help_text" rows="7"><?=$ui_texts['help_text'];?></textarea>
|
||||||
</div>
|
</div>
|
||||||
<button class="btn btn-success" id="edit_selected" data-item="null" data-id="uitexts" data-api-url='edit/ui_texts' data-api-attr='{}' href="#"><span class="glyphicon glyphicon-check"></span> <?=$lang['admin']['save'];?></button>
|
<button class="btn btn-success" id="edit_selected" data-item="ui" data-id="uitexts" data-api-url='edit/ui_texts' data-api-attr='{}' href="#"><span class="glyphicon glyphicon-check"></span> <?=$lang['admin']['save'];?></button>
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -25,6 +25,11 @@ function api_log($postarray) {
|
||||||
}
|
}
|
||||||
if ($value = json_decode($value, true)) {
|
if ($value = json_decode($value, true)) {
|
||||||
unset($value["csrf_token"]);
|
unset($value["csrf_token"]);
|
||||||
|
foreach ($value as $key => &$val) {
|
||||||
|
if(preg_match("/pass/i", $key)) {
|
||||||
|
$val = '********';
|
||||||
|
}
|
||||||
|
}
|
||||||
$value = json_encode($value);
|
$value = json_encode($value);
|
||||||
}
|
}
|
||||||
$data_var[] = $data . "='" . $value . "'";
|
$data_var[] = $data . "='" . $value . "'";
|
||||||
|
|
Loading…
Reference in New Issue