Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install to /usr/lib64/sasl2 instead of /usr/lib/sasl2 #10

Open
JoePater opened this issue Jun 1, 2022 · 5 comments
Open

Install to /usr/lib64/sasl2 instead of /usr/lib/sasl2 #10

JoePater opened this issue Jun 1, 2022 · 5 comments

Comments

@JoePater
Copy link

JoePater commented Jun 1, 2022

I just spent a good 4 hours trying to figure out why mbsync couldn't detect XOAUTH2 as an authentication method - turns out it's because my distro's cyrus-sasl package installs to /usr/lib64/sasl2, so it wasn't detecting the plugins installed in /usr/lib/sasl2. Changing the pkglibdir variable in the makefile to "${CYRUS_SASL_PREFIX}/lib64/sasl2" fixed it. Might be worth mentioning in the README that this might be an issue.

@derekperrin
Copy link

How did you discover this??

I tried using this plugin a year ago and couldn't get it to work, so I gave up. I thought I'd take another crack at it today and saw this issue and it resolved my problem.

@JoePater
Copy link
Author

How did you discover this??

I tried using this plugin a year ago and couldn't get it to work, so I gave up. I thought I'd take another crack at it today and saw this issue and it resolved my problem.

I can't remember exactly. I think I found that the program 'pluginviewer' (which I had compiled from scratch from the latest release of cyrus-sasl, and was therefore configured for the usual /usr/lib/sasl2 path) could detect XOAUTH2, but 'sasl2-shared-mechlist' (configured for lib64) could not. I wrote a short C program to replicate the functionality of sasl2-shared-mechlist that initialised libsasl2 then slept indefinitely, then I used pldd to see what shared libraries the program had pulled in. That revealed it was using lib64.

So not a quick fix! What's worse, after a full day trying to get all this to work, it turns out my uni has IMAP disabled, so it was all for nothing. Glad it helped you though.

@averter
Copy link

averter commented Aug 1, 2022

Thanks. This was helpful. For people using debian the installation should be in a different directory: ${CYRUS_SASL_PREFIX}/lib/x86_64-linux-gnu/sasl2% as comprehensively detailed here. Hope this also helps others.
Clearly someone should write this info of cyrus-sasl-xoauth2 in the steps.org of oauth2ms.

@georgepestell
Copy link

So not a quick fix! What's worse, after a full day trying to get all this to work, it turns out my uni has IMAP disabled, so it was all for nothing. Glad it helped you though.

Hey thanks so much! This worked great on fedora 37 (workspace).

On another note, send an email to your uni IT department they usually can (and hopefully will) give IMAP (and SMTP) access on a per-user basis if you ask.

@mujo-hash
Copy link

Thanks @JoePater for reporting this issue and your fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants