function httpbl_request_whitelist in http:BL 5
Same name and namespace in other branches
- 6.2 httpbl.module \httpbl_request_whitelist()
- 6 httpbl.module \httpbl_request_whitelist()
- 7 httpbl.module \httpbl_request_whitelist()
1 string reference to 'httpbl_request_whitelist'
- httpbl_menu in ./
httpbl.module - Implementation of hook_menu().
File
- ./
httpbl.module, line 488 - Implementation of http:BL for Drupal. It provides IP-based blacklisting through http:BL and allows linking to a honeypot.
Code
function httpbl_request_whitelist() {
if (httpbl_blacklisted() != 2 || $_SESSION['httpbl_status'] != 'grey') {
drupal_access_denied();
exit;
}
$form['#redirect'] = 'node';
$form['reason'] = array(
'#type' => 'textarea',
'#title' => t('Reason for block'),
'#size' => 60,
'#required' => TRUE,
);
$form['block'] = array(
'#type' => 'textfield',
'#title' => t('Leave this blank'),
'#size' => 15,
);
$form['leave'] = array(
'#type' => 'textfield',
'#size' => 30,
'#attributes' => array(
'style' => 'display: none',
),
);
$form['submit'] = array(
'#type' => 'submit',
'#value' => t('Whitelist request'),
);
return $form;
}