summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--inc/HTTPClient.php12
-rw-r--r--inc/auth.php18
2 files changed, 29 insertions, 1 deletions
diff --git a/inc/HTTPClient.php b/inc/HTTPClient.php
index f59efbaf8..7efe39a9c 100644
--- a/inc/HTTPClient.php
+++ b/inc/HTTPClient.php
@@ -158,6 +158,18 @@ class HTTPClient {
$this->error = '';
$this->status = 0;
+ $httpdata = array('url' => $url,
+ 'data' => $data,
+ 'method' => $method);
+ $evt = new Doku_Event('HTTPCLIENT_REQUEST_SEND',$httpdata);
+ if($evt->advise_before()){
+ $url = $httpdata['url'];
+ $data = $httpdata['data'];
+ $method = $httpdata['method'];
+ }
+ $evt->advise_after();
+ unset($evt);
+
// parse URL into bits
$uri = parse_url($url);
$server = $uri['host'];
diff --git a/inc/auth.php b/inc/auth.php
index e1f9029a9..c3480b725 100644
--- a/inc/auth.php
+++ b/inc/auth.php
@@ -81,7 +81,23 @@
// external trust mechanism in place
$auth->trustExternal($_REQUEST['u'],$_REQUEST['p'],$_REQUEST['r']);
}else{
- auth_login($_REQUEST['u'],$_REQUEST['p'],$_REQUEST['r'],$_REQUEST['http_credentials']);
+ $evdata = array(
+ 'action' => $ACT,
+ 'user' => $_REQUEST['u'],
+ 'password' => $_REQUEST['p'],
+ 'sticky' => $_REQUEST['r'],
+ 'silent' => $_REQUEST['http_credentials'],
+ );
+ $evt = new Doku_Event('AUTH_LOGIN_CHECK',$ACT);
+ if($evt->advise_before()){
+ auth_login($evdata['user'],
+ $evdata['password'],
+ $evdata['sticky'],
+ $evdata['silent']);
+ }
+ $evt->advise_after();
+ unset($evt);
+ unset($evdata);
}
}