[JIRA] (JENKINS-43386) Not sending mail to user with permission to view

860 views
Skip to first unread message

dimeolafan@yahoo.com (JIRA)

unread,
Aug 28, 2018, 10:22:02 AM8/28/18
to jenkinsc...@googlegroups.com
Todd B commented on Bug JENKINS-43386
 
Re: Not sending mail to user with permission to view

We recently updated from a quite old version (1.6 ish) and this is now happening to us too. We have users with employee numbers and then also vanity e-mails. In the logs, it complains that the vanity e-mails do not have permission to view job. I have tried to artificially give "them" permission and so far no luck. This is using the Roles Based permissions (which seems to work fine) except that only some e-mails are going out.

Add Comment Add Comment
 
This message was sent by Atlassian Jira (v7.11.2#711002-sha1:fdc329d)

david@vanlaatum.id.au (JIRA)

unread,
Aug 28, 2018, 10:20:02 PM8/28/18
to jenkinsc...@googlegroups.com

Todd B That suggests that the email attached to the jenkins user is not the email it's trying to send to, they must match or it will put them into the no access category. And by jenkins user I mean the one they login to not the fake users you see under the people link that it creates for each seen committer 

dimeolafan@yahoo.com (JIRA)

unread,
Sep 12, 2018, 2:38:03 PM9/12/18
to jenkinsc...@googlegroups.com
Todd B commented on Bug JENKINS-43386

David van Laatum You are right and that is what is in most logs/consoles. Not sure if I can force this or not. We login with our employee number which is a LDAP server, I think. In our CM tool, we have first...@company.com. So, then Jenkins seems to find both the CM variation and the number @ company.com. I tried editing some of the "people" to use the other e-mail and so far no luck.

david@vanlaatum.id.au (JIRA)

unread,
Sep 12, 2018, 10:00:03 PM9/12/18
to jenkinsc...@googlegroups.com

Not sure if it will just get undone again but users can try login to jenkins clicking their name up in the top right then configure on the left and changing their email

dimeolafan@yahoo.com (JIRA)

unread,
Sep 28, 2018, 9:35:05 AM9/28/18
to jenkinsc...@googlegroups.com
Todd B commented on Bug JENKINS-43386

After many unsuccessful tries to give "unknown" users read access, I found this is the only way which essentially disables the security. In particular, I used the second one below and e-mail notification seem to be back to our normal. Bummer there isn't a better way. Also, it seems I only needed to do this on the master (which after digging, I found that modifying the jenkins.xml was the easiest way).

 

If the security fix is undesirable in a particular instance, it can be disabled with either or both of the following two system properties:

  • -Dhudson.tasks.MailSender.SEND_TO_UNKNOWN_USERS=true: send mail to build culprits even if they do not seem to be associated with a valid Jenkins login.
  • -Dhudson.tasks.MailSender.SEND_TO_USERS_WITHOUT_READ=true: send mail to build culprits associated with a valid Jenkins login even if they would not otherwise have read access to the job.

matt.drees@cru.org (JIRA)

unread,
Nov 7, 2018, 12:48:02 PM11/7/18
to jenkinsc...@googlegroups.com

We've run into this too. We're using the " Github Authentication Plugin" and the "GitHub Committer Authorization Strategy". I noticed it appears that email addresses owned by admins (as defined by users listed in the GitHub Authorization Settings->Admin User Names field) are not filtered out. Non-admin jenkins user's email addresses are filtered out with the "Not sending mail to user us...@cru.org with no permission to view" message.

 

So this leads me to hypothesize there's a bug in either the github plugin, or how it is used by other components for authorization decisions.

steve.graham@siemens.com (JIRA)

unread,
May 14, 2019, 2:49:01 AM5/14/19
to jenkinsc...@googlegroups.com

Just updated my Gitlab Oauth settings with a Group name for all users. Works as expected, only authorised users who belong to the group set on Gitlab can log in to Jenkins 

Unfortunately I also now get the messages 

Not sending mail to user <username@...> with no permission to view <Jenkins Jobname> 

If I set Global Security->Gitlab OAuth Settings -> Authenticated Users to allow View Read it works ok.

if I set the same using the Group Name ist does not work.

I would rate this as a more serious bug - I will try the workaround mentioned above ( SEND_TO_USERS_WIITHOUT_READ ) - it is a workaround.

( I also had to set SEND_TO_UNKNOWN_USERS a long time ago... - also a bug, users are known)

Jenkins Version 2.176 ( just about to go to 2.177)

Email Extension plugin  - 2.66

Gitlab OAuth 1.4

 

adams.david.10@gmail.com (JIRA)

unread,
May 24, 2019, 1:12:06 PM5/24/19
to jenkinsc...@googlegroups.com

Experiencing similar issues as Steve Graham. Using github oauth client for a github organization and can't get email to send. I've tried checking "Allow sending to unregistered users" with no change. I still get: 

"Not sending mail to user mye...@gmail.com with no permission to view My Project » my-branch#40An attempt to send an e-mail to empty list of recipients, ignored."

slide.o.mix@gmail.com (JIRA)

unread,
Jul 17, 2019, 10:59:02 AM7/17/19
to jenkinsc...@googlegroups.com
Alex Earl assigned an issue to Alex Earl
 
Jenkins / Bug JENKINS-43386
Change By: Alex Earl
Assignee: David van Laatum Alex Earl

luckyhk.lee@samsung.com (JIRA)

unread,
Aug 30, 2019, 7:44:05 AM8/30/19
to jenkinsc...@googlegroups.com
Hokwang Lee commented on Bug JENKINS-43386
 
Re: Not sending mail to user with permission to view

suffering this problem, one more here.

Reply all
Reply to author
Forward
0 new messages