Summary | IMP ACL - ACL capability may not be available until after login. |
Queue | IMP |
Queue Version | 4.3.8 |
Type | Bug |
State | Resolved |
Priority | 3. High |
Owners | slusarz (at) horde (dot) org |
Requester | robert (at) schetterer (dot) org |
Created | 05/26/2010 (5555 days ago) |
Due | |
Updated | 10/19/2010 (5409 days ago) |
Assigned | 07/28/2010 (5492 days ago) |
Resolved | 07/28/2010 (5492 days ago) |
Github Issue Link | |
Github Pull Request | |
Milestone | |
Patch | No |
a folder named test-1 must be quoted
Bug #9299tested the your diff from git(cvs)
it works now, but my tests show that acls of folders named i.e with -
like test-1 etc cant be displayed, not sure if it ever worked, any idea?
Regards
a folder named test-1 must be quoted
( whatever ist the problem to quote all folders ? )
the workaround (problem ) is
in rfc2086.php
the preg_match \W is not save ( save here means working or not ) to
use in any setup cause it depends to the servers config
therefor it should be avoided ( google for that )
[^A-Za-z0-9] should match any symbol not a letter or number
so it might be a workaround
i am no php hacker and i dont know if these brakes other functions or
security anyway
but it should not be a big thing for horde coders to review and fix this bug
so the ticket is definite not resolved yet ( unless it has no or minor
connect to the starting bug thread )
/**
* Attempts to retrieve the existing ACL for a folder from the current
* IMAP server.
*
* NB: if Auth_SASL is not installed this function will send the users
* password to the IMAP server as plain text!!
*
* @param string folder The folder to get the ACL for.
*
* @return array A hash containing information on the ACL.
* <pre>
* Array (
* user => Array (
* right => 1
* )
* )
* </pre>
*/
function getACL($folder)
{
/* Quote the folder string if it contains non alpha-numeric
characters. */
// if (preg_match('/\W/',$folder)) {
if (preg_match('[^A-Za-z0-9]',$folder)) {
$folder = '"' . $folder . '"';
}
tested the your diff from git(cvs)
it works now, but my tests show that acls of folders named i.e with -
like test-1 etc cant be displayed, not sure if it ever worked, any idea?
Regards
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horde&r1=1.6.8.25&r2=1.6.8.26&ty=u
This started happening somewhere around the end of August. Since
then, all links for CVS have their '&' stripped.
Bug: 9058Catch untagged responses after login and discard.
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horder1=1.6.8.25r2=1.6.8.26ty=u
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horde&r1=1.6.8.25&r2=1.6.8.26&ty=u
This started happening somewhere around the end of August. Since then,
all links for CVS have their '&' stripped.
Bug: 9058Catch untagged responses after login and discard.
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horder1=1.6.8.25r2=1.6.8.26ty=u
Summary ⇒ IMP ACL - ACL capability may not be available until after login.
Version ⇒ 4.3.8
Bug: 9058Catch untagged responses after login and discard.
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horder1=1.6.8.25r2=1.6.8.26ty=u
:). I didn't know it was able to do so.
I didn't know it was able to do so.
ACLs have to be defined somewhere else since Horde doesn't support
managing rights, but after having defined some rights in Thunderbird,
the shared folder will automagically appear and it's possible to
browse all shared folders.
There is no need to define any acl property in servers.php
Horde Webmail Edition and Dovecot 2.0.5
if (substr($this->_params['protocol'], 0, 4) != 'imap') {
/* No point in going any further if it's not an IMAP server. */
// $this->_error = PEAR::raiseError(_("Only IMAP servers
support shared folders."));
$this->_supported = true;
}
//else {
// $this->_caps = $this->_getCapability();
// if (is_a($this->_caps, 'PEAR_Error')) {
// $this->_error = $this->_caps;
// return;
//}
/* If we couldn't get the server's capability, assume ACL is
* not supported for now. */
$this->_supported = true;
//}
as i have loadbalanced servers i will let stay the other install in
orginal, so testing
is no Problem with the orginal code be easy switching servers
And this code *does* work, because it has been tested by at least
two different developers. So the question is why is it not working
on your system, and you are the only one in the position to help us
out with that.
in horde log , ( full error ph log is enabled ) but i will help to
find out whats going wrong
describe how to debug the problem
acl imap work on my setup with thunderbird and acl extension
so its not a server problem,the server entries were not changed at
upgrade so the only logical solution
seems that the problem is on the client side
And this code *does* work, because it has been tested by at least two
different developers. So the question is why is it not working on
your system, and you are the only one in the position to help us out
with that.
this bug and how to
manipulate capability,
horde 3.9 still does not report folder sharing, no debug logs what
might happen apear
so i dont see this as resolved, guess your code is buggy and there is
no workaround yet
so i might revert my horde install where my code workaround posted
did worked
http://comments.gmane.org/gmane.mail.imap.dovecot/47967
there and report
this down, especially since this is not an issue in IMP 5 and because
with the current horde stable code, after all i would install all from
cvs , if there would be a good description how to do that ( cant find
), or better way a snapshot release from cvs upcomming
horde groupware with imp5 horde 4 etc should be on the net, also would
be good for testing
the ACL capability strings to the capability returned by dovecot
pre-auth.
so you have to insert all capability you want to use later
if that is still true , this is an ugly workaround, which might leads
brake other stuff
if its enough to insert capability acl only in pre auth, its acceptable
as there might be other buggy clients around
do you have a link or mail with a description from Timo ( dovecot developer )
where he describes this expliciet way ?
I personally don't have the time to devote any more time to tracking
this down, especially since this is not an issue in IMP 5 and because
this can also be fixed easily at the dovecot level by simply adding
the ACL capability strings to the capability returned by dovecot
pre-auth.
and newest Webmail (imp) H3 (4.3.8) by upgrade from yesterday stable release
i see you have changed the code but its not working
message is server does not support folder sharing, can you double check this ?
also by code change my workaround does not longer work
any hints how do a better debug or parameter may changed i have to set new?
additional info imap acl is working with thunderbird imap acl add_on
Regards
State ⇒ Resolved
Make sure to always read the complete IMAP response, now that we re-use the
IMAP stream and don't close it after each operation (
Bug #9058).Still slow like hell.
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horde&r1=1.6.8.23&r2=1.6.8.24&ty=u
Bug: 9058Next back of variable fixups.
Fixing this old IMAP code makes my realize how grateful I am that we now have
a fully encapsulated, robust IMAP library. No need to hack all this IMAP
connection stuff anymore.
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horde&r1=1.6.8.22&r2=1.6.8.23&ty=u
( ! ) Warning: Missing argument 1 for _getcapability() in
/srv/www/htdocs/horde/framework/IMAP/IMAP/ACL/rfc2086.php on line 218
Call Stack
# Time Memory Function Location
1 0.0014 62520 {main}( ) ../prefs.php:0
2 0.2609 5651000 require( '/srv/www/htdocs/horde/imp/acl.php'
) ../prefs.php:57
3 0.2697 5915544 imp_imap_acl::singleton( ) ../acl.php:42
4 0.2698 5916096 imp_imap_acl::factory( ) ../ACL.php:82
5 0.2737 6048288 imp_imap_acl_rfc2086->imp_imap_acl_rfc2086( ) ../ACL.php:55
6 0.2737 6048376 imap_acl_rfc2086::imap_acl_rfc2086( ) ../rfc2086.php:46
7 0.2737 6049344 imp_imap_acl_rfc2086->_getcapability( ) ../rfc2086.php:77
( ! ) Notice: Undefined variable: txid in
/srv/www/htdocs/horde/framework/IMAP/IMAP/ACL/rfc2086.php on line 478
Call Stack
# Time Memory Function Location
1 0.0014 62520 {main}( ) ../prefs.php:0
2 0.2609 5651000 require( '/srv/www/htdocs/horde/imp/acl.php'
) ../prefs.php:57
3 0.2697 5915544 imp_imap_acl::singleton( ) ../acl.php:42
4 0.2698 5916096 imp_imap_acl::factory( ) ../ACL.php:82
5 0.2737 6048288 imp_imap_acl_rfc2086->imp_imap_acl_rfc2086( ) ../ACL.php:55
6 0.2737 6048376 imap_acl_rfc2086::imap_acl_rfc2086( ) ../rfc2086.php:46
7 0.2737 6049344 imp_imap_acl_rfc2086->_getcapability( ) ../rfc2086.php:77
8 0.2744 6049424 imp_imap_acl_rfc2086->_internallogin( ) ../rfc2086.php:223
( ! ) Notice: Undefined variable: txid in
/srv/www/htdocs/horde/framework/IMAP/IMAP/ACL/rfc2086.php on line 481
Call Stack
# Time Memory Function Location
1 0.0014 62520 {main}( ) ../prefs.php:0
2 0.2609 5651000 require( '/srv/www/htdocs/horde/imp/acl.php'
) ../prefs.php:57
3 0.2697 5915544 imp_imap_acl::singleton( ) ../acl.php:42
4 0.2698 5916096 imp_imap_acl::factory( ) ../ACL.php:82
5 0.2737 6048288 imp_imap_acl_rfc2086->imp_imap_acl_rfc2086( ) ../ACL.php:55
6 0.2737 6048376 imap_acl_rfc2086::imap_acl_rfc2086( ) ../rfc2086.php:46
7 0.2737 6049344 imp_imap_acl_rfc2086->_getcapability( ) ../rfc2086.php:77
8 0.2744 6049424 imp_imap_acl_rfc2086->_internallogin( ) ../rfc2086.php:223
( ! ) Notice: Undefined variable: login in
/srv/www/htdocs/horde/framework/IMAP/IMAP/ACL/rfc2086.php on line 484
Call Stack
# Time Memory Function Location
1 0.0014 62520 {main}( ) ../prefs.php:0
2 0.2609 5651000 require( '/srv/www/htdocs/horde/imp/acl.php'
) ../prefs.php:57
3 0.2697 5915544 imp_imap_acl::singleton( ) ../acl.php:42
4 0.2698 5916096 imp_imap_acl::factory( ) ../ACL.php:82
5 0.2737 6048288 imp_imap_acl_rfc2086->imp_imap_acl_rfc2086( ) ../ACL.php:55
6 0.2737 6048376 imap_acl_rfc2086::imap_acl_rfc2086( ) ../rfc2086.php:46
7 0.2737 6049344 imp_imap_acl_rfc2086->_getcapability( ) ../rfc2086.php:77
8 0.2744 6049424 imp_imap_acl_rfc2086->_internallogin( ) ../rfc2086.php:223
State ⇒ Feedback
$folder issue. Unfortunately, I have no way of testing on a live IMAP
system though.
Bug: 9058Fix undefined variables
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horde&r1=1.6.8.21&r2=1.6.8.22&ty=u
with the patch, and now a bunch of variables are undefinded because
that had only been defined in the old places, like $authMech, $folder.
available anymore etc.
Priority ⇒ 3. High
State ⇒ Assigned
available anymore etc.
Priority ⇒ 1. Low
State ⇒ Feedback
Assigned to Michael Slusarz
Bug: 9058Need to grab CAPABILITY string after login, since ACL does not need to be
broadcast pre-login.
http://cvs.horde.org/diff.php/framework/IMAP/Attic/package.xml?rt=horde&r1=1.17.8.4&r2=1.17.8.5&ty=u
http://cvs.horde.org/diff.php/framework/IMAP/IMAP/ACL/Attic/rfc2086.php?rt=horde&r1=1.6.8.20&r2=1.6.8.21&ty=u
Priority ⇒ 3. High
State ⇒ Unconfirmed
Patch ⇒ No
Milestone ⇒
Queue ⇒ IMP
Type ⇒ Bug
Summary ⇒ imp imap acl with comming dovecot2 version capability bug
using imap acls as tested
dovecot Timo Sirainen developer changed acl behavior, clients should be fixed
more info
http://dovecot.org/list/dovecot/2010-April/048147.html
slusarz@horde.org wrote
This works fine in IMP 5. The problem with IMP 4 is that c-client
doesn't support the CAPABILITY command so we have to use hackish ways
to work around it.
You should open a ticket re: this issue on http://bugs.horde.org/
meanwhile as workaround i found
horde/imp does a check which seems to get workarounded by
horde/lib/Horde/IMAP/ACL/rfc2086.php
if (substr($this- _params['protocol'], 0, 4) != 'imap') {
/* No point in going any further if it's not an IMAP server. */
$this- _error = PEAR::raiseError(_("Only IMAP servers
support shared folders."));
$this- _supported = false;
} elseif (!isset($this- _caps['acl'])) {
/* If we couldn't get the server's capability, we'll assume
ACL is
not supported for now. */
----change---from---false---to---true
$this- _supported = true;
} else {
$this- _supported = true;
}
the alternate workaround with dovecot
is setting manual imap capability list
didnt tested that yet