mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
thanks to POST we can remove url_encoding and prevent issues here
This commit is contained in:
@@ -1185,7 +1185,7 @@ class User extends CI_Controller {
|
||||
}
|
||||
|
||||
// decrypt the hash
|
||||
$user_id = $this->encryption->decrypt(urldecode($this->input->post('hash', TRUE) ?? ''));
|
||||
$user_id = $this->encryption->decrypt($this->input->post('hash', TRUE) ?? '');
|
||||
|
||||
// make sure the user_id is a number
|
||||
if (!is_numeric($user_id)) {
|
||||
|
||||
@@ -101,7 +101,7 @@
|
||||
<?php
|
||||
if ($session_uid != $row->user_id) { ?>
|
||||
<form action="<?php echo site_url('user/impersonate'); ?>" method="post" style="display:inline;">
|
||||
<input type="hidden" name="hash" value="<?php echo urlencode($this->encryption->encrypt($row->user_id)); ?>">
|
||||
<input type="hidden" name="hash" value="<?php echo $this->encryption->encrypt($row->user_id); ?>">
|
||||
<button type="submit" class="btn btn-info btn-sm"><i class="fas fa-people-arrows"></i></button>
|
||||
</form>
|
||||
<?php }
|
||||
|
||||
Reference in New Issue
Block a user