Revize 53cf4ce8
Přidáno uživatelem Ondřej Fibich před téměř 8 roky(ů)
application/controllers/web_interface.php | ||
---|---|---|
|
||
/**
|
||
* Prints all unallowed ip addresses, otherwise same as previous method
|
||
*
|
||
* @author Michal Kliments
|
||
*
|
||
* @param int $message_type message type to filter only IP redirected with
|
||
* the specified type or NULL for all types
|
||
* @author Michal Kliment
|
||
* @author Ondřej Fibich
|
||
*/
|
||
public function unallowed_ip_addresses()
|
||
public function unallowed_ip_addresses($message_type = NULL)
|
||
{
|
||
// if gateway set uped - anly allow to access this page from it
|
||
// also if redirection is not enabled
|
||
... | ... | |
@header('HTTP/1.0 403 Forbidden');
|
||
die();
|
||
}
|
||
|
||
$ip_adresses = ORM::factory('ip_address')->get_unallowed_ip_addresses();
|
||
|
||
$ipm = new Ip_address_Model();
|
||
$mt_num = intval($message_type);
|
||
if ($message_type != NULL && $mt_num >= 0)
|
||
{
|
||
$ip_adresses = $ipm->get_unallowed_ip_addresses_by_type($mt_num);
|
||
}
|
||
else
|
||
{
|
||
$ip_adresses = $ipm->get_unallowed_ip_addresses();
|
||
}
|
||
|
||
$items = array();
|
||
|
Také k dispozici: Unified diff
Resolves #1060: implement filter for message type in Web interface unallowed_ip_addresses