2011-09-29 16:09:59 +00:00
|
|
|
<?php
|
|
|
|
interface gatewayBackend
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
*
|
|
|
|
* @param String $username
|
|
|
|
* @param String $password
|
|
|
|
* @param String $ip
|
|
|
|
* @param String $sessionId
|
|
|
|
* @return String $token
|
|
|
|
*/
|
2011-09-29 16:50:21 +00:00
|
|
|
public function getToken($username, $password, $ip, $sessionId);
|
|
|
|
|
|
|
|
/**
|
|
|
|
*
|
|
|
|
* @param String $token
|
|
|
|
* @param String $sessionId
|
|
|
|
* @param String $ip
|
|
|
|
* @return Boolean
|
|
|
|
*/
|
|
|
|
public function checkToken($token, $sessionId, $ip);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* removeToken() Remove a logged out user's token
|
|
|
|
*
|
2011-09-30 11:42:45 +00:00
|
|
|
* @param String $ip
|
|
|
|
* @param String $sessionId
|
2011-09-29 16:50:21 +00:00
|
|
|
* @param String $token
|
|
|
|
*/
|
2011-09-30 11:42:45 +00:00
|
|
|
public function removeToken($ip, $sessionId, $token);
|
2011-09-29 16:09:59 +00:00
|
|
|
|
2011-09-29 16:50:21 +00:00
|
|
|
/**
|
|
|
|
* auditLog() Log audit messages
|
|
|
|
*
|
|
|
|
* @param String $ip
|
|
|
|
* @param String $event
|
|
|
|
* @param String $message
|
|
|
|
*/
|
|
|
|
public function auditLog($ip, $event, $message);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* messageLog() Log sent messages
|
|
|
|
*
|
2011-09-30 11:42:45 +00:00
|
|
|
* @param Integer $senderId
|
|
|
|
* @param String $recipient
|
|
|
|
* @param String $message
|
|
|
|
* @param String $ip
|
2011-09-29 16:50:21 +00:00
|
|
|
*/
|
2011-09-30 11:42:45 +00:00
|
|
|
public function messageLog($senderId, $recipient, $message, $ip);
|
2011-09-29 16:09:59 +00:00
|
|
|
}
|
|
|
|
|