Open Bug 1935379 Opened 1 year ago Updated 5 months ago

no prompt to enter password for new smtp ("enter new password" doesn't do anything) when failing to send using OAuth2 using microsoft365 account

Categories

(Thunderbird :: Account Manager, defect)

Thunderbird 134
defect

Tracking

(Not tracked)

People

(Reporter: acdp, Unassigned)

References

Details

Attachments

(9 files)

I have set up a new SMTP config and when using for the first time I am advised no password or wrong (expected as not configured yet)

When selecting "enter new password" option, the Send retries to send when I should get a window to enter the new password.

Unable to enter the new smtp details into the password section manually.

This is quite urgent as added a new account that needs to use a new SMTP setup but not able to do so as unable to set a opw for it and new smtp settings not being added to Account Manager (password control)

Component: General → Account Manager
OS: Unspecified → macOS
Hardware: Unspecified → ARM64

Unable to enter the new smtp details into the password section manually.

It is expected that there is no section to enter details, but that you'll be asked the first time needed.

I'm not sure what you're reporting. Did you not get the input prompt?

(In reply to Magnus Melin [:mkmelin] from comment #2)

Unable to enter the new smtp details into the password section manually.

It is expected that there is no section to enter details, but that you'll be asked the first time needed.

I'm not sure what you're reporting. Did you not get the input prompt?

Magnus,

as you note on first use one is prompted for the opw for smtp as there is no entry, i get the prompt advising to enter, but no input window follows for me to enter the pow and so setup the smtp entry, the Send function goes back trying to send

Can you provide screenshots?

Related to bug 1928026?

(In reply to Magnus Melin [:mkmelin] from comment #4)

Can you provide screenshots?

as requested
1 shot of the smtp settings, 1 of the Password account showing no smtp for this domain 2020pm.uk and the video showing trying to send and get the pw prompt but no window to enter the new ow to set up the new smtp

Attached image smtp settings

Ok, so that account is set to use OAuth2. You can't enter a new password for that (as it's not using passwords).
I guess the authentication failure happened due to some other issue.
An smtp protocol log may give some clues. See https://wiki.mozilla.org/MailNews:Logging

Summary: no prompt to enter password for new smtp → no prompt to enter password for new smtp ("enter new password" doesn't do anything) when failing to send using OAuth2 using microsoft365 account

(In reply to Magnus Melin [:mkmelin] from comment #10)

Ok, so that account is set to use OAuth2. You can't enter a new password for that (as it's not using passwords).
I guess the authentication failure happened due to some other issue.
An smtp protocol log may give some clues. See https://wiki.mozilla.org/MailNews:Logging

Magnus, prob is Microsoft changed the authentication req'ts recently to need OAuth2...

I'll look up logs and also try other autho methods

going to uoload a couple of error log screenshots of other smtp settings, but no joy with either

in case you can gleam something from them - or suggest other settings

error when sending with the "correct" settings

21:00:26.896
mailnews.smtp: Command failed: 535 Authentication unsuccessful, SmtpClientAuthentication is disabled for the Tenant. Visit https://aka.ms/smtp_auth_disabled for more information. [LO4P123CA0114.GBRP123.PROD.OUTLOOK.COM 2024-12-11T21:00:26.951Z 08DD194B38CC3563]; currentAction=_actionAUTH_XOAUTH2 SmtpClient.sys.mjs:600:19
21:00:26.897 mailnews.smtp: Error during AUTH XOAUTH2, sending empty response SmtpClient.sys.mjs:1119:19
21:00:32.016
mailnews.smtp: Command failed: 500 Unrecognized command 'Length: 7' [LO4P123CA0114.GBRP123.PROD.OUTLOOK.COM 2024-12-11T21:00:31.998Z 08DD194B38CC3563]; currentAction=_actionAUTHComplete SmtpClient.sys.mjs:600:19
21:00:32.016
mailnews.smtp: Authentication failed: Unrecognized command 'Length: 7' [LO4P123CA0114.GBRP123.PROD.OUTLOOK.COM 2024-12-11T21:00:31.998Z 08DD194B38CC3563] SmtpClient.sys.mjs:784:17
21:01:18.571
mailnews.smtp: Authentication failed: Unrecognized command 'Length: 7' [LO4P123CA0114.GBRP123.PROD.OUTLOOK.COM 2024-12-11T21:00:31.998Z 08DD194B38CC3563] SmtpClient.sys.mjs:825:19
21:01:18.581
mailnews.send: Sending failed; Unable to authenticate to Outgoing server (SMTP) smtp.office365.com. Please check the password and verify the 'Authentication method' in 'Account Settings | Outgoing server (SMTP)'., exitCode=2153066805, originalMsgURI=

tried a number of permutations of settings, this is the only one that says "enter new pw", but when selected does not go to the window to acutally enter the pw

see screenshot

there has ti be a way, I have searched but cannot find any other settings to use, besides all the variations I have already tried.

TB is not being triggered to enter the smtp details in password manager, I am aware that the entry, when there, is a coded pw

see other screenshot

I have to use one that is set for my own email domain with smtp serviced by the server on the hosting site

this is my outlook account smtp
setting, when I tried this one got a msg "cannot my outlook email address smtp settings for another accoutn" or something like that

see note above

See bug 1917321 comment 24. If you have aliases (on server side) in use, you need to use the main identity.

(In reply to Antony from comment #20)

Created attachment 9443668 [details]

This seems to explain it pretty well. You're not sending with the right username/address.

(In reply to Magnus Melin [:mkmelin] from comment #21)

See bug 1917321 comment 24. If you have aliases (on server side) in use, you need to use the main identity.

No aliases

(In reply to Antony from comment #23)

(In reply to Magnus Melin [:mkmelin] from comment #21)

See bug 1917321 comment 24. If you have aliases (on server side) in use, you need to use the main identity.

No aliases

I think you missed the details

I have an account antony@2020pm.uk with a company that uses office365 so I get my emails from the server as normal,
Whern sending I cannot get the smtp to work using the details in Screenshot 2024-12-10 at 21.13.09 pic.

So I use the smtp with my own domain and my account there is acdp@projectradar.uk, which works, Screenshot 2024-12-14 at 20.14.42

I also have an outlook account, acdp@outlook.com, I added this detail to show that although the smtp settings work for this account, they cannot be used for my 2020PM account. I tried this. Ther eis no relationship between the two addresses

When I originally set up the acdp@outlook.com it was before microsoft, in their "wisdom", decided to change the authentication format to OAuth2, so I already had an smtp entry, just needed to change the type and PW.

For some reason, no matter what entries I use for smtp, I cannot get it to work, or even add an entry to the password manager, some timeout, others ask for the "new pw" but do not offer a place to enter it.

Hope this makes sense to you now... :-)

(In reply to Antony from comment #24)

I also have an outlook account, acdp@outlook.com, I added this detail to show that although the smtp settings work for this account, they cannot be used for my 2020PM account. I tried this. Ther eis no relationship between the two addresses

Yes I don't know why you think that should work.
The 2020PM office account needs to use its own smtp setting, it can't share the setting of someone else.

(In reply to Magnus Melin [:mkmelin] from comment #25)

(In reply to Antony from comment #24)

I also have an outlook account, acdp@outlook.com, I added this detail to show that although the smtp settings work for this account, they cannot be used for my 2020PM account. I tried this. Ther eis no relationship between the two addresses

Yes I don't know why you think that should work.
The 2020PM office account needs to use its own smtp setting, it can't share the setting of someone else.

I was not expecting it to at all.. elimination
The 2020PM office account needs to use its own smtp setting, it can't share the setting of someone else. - actually it is using my projectradar smtp settings and working
Any Office365 account will need to have its own settings, security reasons for one, and the other escapes me, but years ago we could not do this either and there is a word/phrase for it, piggy-backing, "subrouting" i seem to remember

Magnus, I come from a hardware and network engineer background (way before DOS, back to CP/M etc) and built a few systems, so understand most of the configs back to before MSMail - background is in trouble shooting etc, hence why I will try all variations, some of which I know dont work, but to eliminate :-)

FWIW: I think I also stumbled on this scenario - or a quite similar one.
I set up without too much fuss a TB account for an office365 mailbox, using POP+SMTP, but while POP would WORK, SMTP would not.
When trying to send an email, TB would show a "cancel/re-enter password" question.
But then, if clicking "re-enter password", TB would not show any further dialog windows.

I think that re-entering a password might not be the correct option for oauth accounts - but a better user experience would be to

  • either not show the "re-enter password" button, or
  • force the oauth provider to pop-up again the page where it asks about granting access t the external app (TB)

In the end, the issue was with the Office365 configuration: that specific account had POP and IMAP access enabled, but not SMTP. Changing that fixed the problem.

ps: possibly related issues: bug 1881998, bug 1939939

Please prefix bug numbers with "bug", then bugzilla will properly link it. Thanks.

OS: macOS → All
Hardware: ARM64 → All
See Also: → 1939939

(In reply to Gaetano Giunta from comment #27)

FWIW: I think I also stumbled on this scenario - or a quite similar one.
I set up without too much fuss a TB account for an office365 mailbox, using POP+SMTP, but while POP would WORK, SMTP would not.
When trying to send an email, TB would show a "cancel/re-enter password" question.
But then, if clicking "re-enter password", TB would not show any further dialog windows.

I think that re-entering a password might not be the correct option for oauth accounts - but a better user experience would be to

  • either not show the "re-enter password" button, or
  • force the oauth provider to pop-up again the page where it asks about granting access t the external app (TB)

In the end, the issue was with the Office365 configuration: that specific account had POP and IMAP access enabled, but not SMTP. Changing that fixed the problem.

I also checked the config at the server end for this and found the same situ - SMTP was not enabled!!!

I am looking to get this sorted and will advise if this wiorks for me as well

Microsoft actually gives a quite complete error message. It can be viewed from TB on its console with ctrl-shift-J
Authentication failed: Authentication unsuccessful, SmtpClientAuthentication is disabled for the Tenant. Visit https://aka.ms/smtp_auth_disabled for more information.
It would be better to present the end-user of TB with this information, instead of a password prompt (that will not solve the tenant setting issue).

behaviour still present in a newly installed thunderbird 138.0 (64-bits) . related to bug1917321

Heya team, this affects Thundermail too. Like I mentioned in bug 1939939, a user can enter this state if they change their password. Could we get this looked at soon?

See Also: → 1974875

OKAY, I have a nother outlook based account i need to add to TB, rx is fine but still cannot get the Enter PW to open up the dialogue to actually enter the pw when sending an email

Please get this fixed soonest

just installed 145.0b1 on macOS 26.0.1 (25A362) Tahoe

At first same issue, asked to enter a new pw, but then back to the send window

Not sure what happened in the meantime but about an hr later (no restart/reboot either) i get the prompt and window to enter the PW, and this enters the smtp info into the Password manager, finally - however, as Office365 etc uses the 2FA function, I am not prompted for the 2nd level so the send fails to log into the 0ffice365 smtp server...

thought just struck me - i have an outlook account whoich I access via TB, this works using the MS smtp.,office365.com - I would have had to set up the original 2fa and the authenticator to get access (in fact i remember re-authenticating recently)

Why does it not work for other accounts logging into smtp with ccount details and asking for the authenticator (2fa), very odd, unless MS is set to only recognise Outlook.com or even the original hotmail.whatever

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: