i have this link but its saying
HTTP ERROR 400
Problem accessing /service/preauth. Reason:
authentication failed for test@test.local
http://zimbra.test.local/service/pre...XXXXXXXXXXXXXX
any suggestions?
is my link correct?
i have this link but its saying
HTTP ERROR 400
Problem accessing /service/preauth. Reason:
authentication failed for test@test.local
http://zimbra.test.local/service/pre...XXXXXXXXXXXXXX
any suggestions?
is my link correct?
It doesn't say the url is incorrect it says that you failed authentication. I assume you followed the wiki article exactly?
Regards
Bill
in most cases, you should call zimbra preauth login via program(php, java, jsp....), cause you need to pass several parameters to zimbra (some of them need to be calculated first) :
1. email account
2. time (in mini-second format? if i remember correctly)
3. hash-key value (using SHA1?)
as Phoenix said, everything is written in that Preauth wiki article.
yeah i already COPY and Paste the code from the wiki and its not working![]()
you should modify it before you use it, and nobody knows what code you got from the wiki?
Same applies for me: preauth is not working, but did work before upgrading 5.0.x to 6.0.4!
I also tried to solve the issue by creating a new preauthentication key and restarting Zimbra - still authentication failed although I can use it from the Admin UI.PHP Code:<?php
session_start();
if ($_SESSION['authenticated'] == true && $_SESSION['auth_type'] == 'internal') {
/**
* Globals. Can be stored in external config.inc.php or retreived from a DB.
*/
$PREAUTH_KEY="1234567890123456789012345678901234567890123456789012345678901234";
$WEB_MAIL_PREAUTH_URL="https://myzimbra/service/preauth";
/**
* User's email address and domain. In this example obtained from a GET query parameter.
* i.e. preauthExample.php?email=user@domain.com&domain=domain.com
* You could also parse the email instead of passing domain as a separate parameter
*/
$user = $_SESSION['UserLogin'];
$domain="mydomain";
$email = "{$user}@{$domain}";
if(empty($PREAUTH_KEY)) {
die("Need preauth key for domain ".$domain);
}
/**
* Create preauth token and preauth URL
*/
$timestamp=time()*1000;
$preauthToken=hash_hmac("sha1",$email."|name|0|".$timestamp,$PREAUTH_KEY);
$preauthURL = $WEB_MAIL_PREAUTH_URL."?account=".$email."&by=name×tamp=".$timestamp."&expires=0&preauth=".$preauthToken;
/**
* Redirect to Zimbra preauth URL
*/
//die($preauthURL);
header("Location: $preauthURL");
} else {
header("Location: http://mydomain/index.php");
}
?>
Has the URL based mechanism been changed or removed without notifiying users...?
I promise I will check my timeservers.
I promise I will check my timeservers.
I promise I will check my timeservers.
I promise I will check...
Solved![]()
Trouble Shooting
Doesn't Work After Upgrade Of ZCS
Please check the data/time on your servers. If they are off by more than 5 minutes preauth will fail.
There are currently 1 users browsing this thread. (0 members and 1 guests)