Jenkins "Invalid Username and Password" PAM Authentication - jenkins

I am running Jenkins 2.164 in RHEL with Centrify as AD connector. I have configured Jenkins security to use PAM. The PAM security configuration test is Success and Matrix Security is also able to validate users and group via PAM. When restarting Jenkins and login, it doesn't seem to be able to authenticate via PAM and keeps getting "invalid username or password error". I am using Pam-Auth plugin version 1.5. The weird part is when I am using an older version of Jenkins 2.89, it works. Also, the new Jenkins has changed the login form to a SimpleLogin and I suspect that causes incompatibility with my Centrify.
I have checked the /var/log/messages file and I keep receiving the following error. This has never happened before in the older version. I am not sure why the older version of Jenkins works but not the current version I'm using.
I've tried to swap to an older version of libpam4j-1.8 before pam_setcred was being introduced in 1.11 version, but still fail.
Any help would be greatly appreciated.
Apr 24 23:45:26 adclient[35963]: INFO AUDIT_TRAIL|Centrify Suite|PAM|1.0|201|PAM set credentials
denied|5|user=test(type:ad,test#testdomain.com) pid=180 utc=1556163926715 centrifyEventID=24201 status=DENIED service=sshd tty=(none) client=(none) reason=Failed to set user credentials

Related

Jenkins fails to send email - Authentication Required

I have a Jenkins server running on a Linux VM. I would like my Jenkins to send me an email every time a build gets started. I have set the email service up as below. As I am using 2 factor authentication for my google account, I have created an app password for Jenkins, but it still says "authentication required". I have also installed the Extended E-mail notification plugin and set it up the exact same way with the same result. Does anyone know what could be the issue here?
I did a test set up and tried using exactly your configuration. I too faced the same issue. Since i had tested this thing long time ago and it worked well then, i knew it had to do with some change in latest plugin version. So i tried downgrading the Mailer plugin from version 1.24 to 1.23 and it worked. :)
You can get the Mailer plugin version 1.23 here.
Details about downgrading a given plugin's version is described here
Note: You don't have to configure Extended E-mail Notification section for this to work. Just leave it as is.

Bitbucket clone to Sourcetree, repeatedly asking for password

I am completely new to Bitbucket and Sourcetree. I have received a repository from my college, when I log into Bitbucket I find it there with all necessary files. I would like to clone it, so i can work with it on my laptop, so I drag it from the website to the Sourcetree window and get requested Source URL, Destination path and Name. Here the problems start, I get repeatedly asked for password, but the password is correct. Do someone have any suggestions? I am running OS X El Capitan Version 10.11.6
Thank you!
I came across the same issue on SourceTree 2.7.3 under OS-X 10.13.6. I was given access to a repository over https and had to clone it. Since even the cloning failed through SourceTree due to "password keep asking issues", I cloned it through Terminal which worked fine. Post that, I could open the locally cloned bitbucket repo through SourceTree, but any git remote operations continue to fail over "password keep asking issues".
I came across several possible workarounds through several posts like
https://community.atlassian.com/t5/Sourcetree-questions/Sourcetree-keeps-asking-for-bitbucket-password-on-windows/qaq-p/241278
https://community.atlassian.com/t5/Sourcetree-questions/Sourcetree-keeps-asking-for-login-and-password/qaq-p/146765
https://community.atlassian.com/t5/Sourcetree-questions/SourceTree-2-7-constantly-asks-for-credentials/qaq-p/711139
https://community.atlassian.com/t5/Bitbucket-questions/Bitbucket-clone-to-Sourcetree-repeatedly-asking-for-password/qaq-p/704242#U919139
Suggested workarounds were
Using latest out of embedded or system git versions and reopened SourceTree
Upgraded SourceTree from 2.7.3 to 2.7.6
Clearing bitbucket entries from keychain and reopened SourceTree
Clearing bitbucket sourceTree cached passed file from ~/Library/Application Support/SourceTree/ and reopened SourceTree
Did not try to downgrade from 2.7.3 to 2.6.3 as suggested by one post wondering what worse might wait for me with an older version :-)
Even restarted the machine without any luck.
At this point, I noticed that my Mac's Gmail synching went offline after sometime due to login issues. Then I recalled that my Atlassian account address is the Gmail-id I used for OAuth integration with BitBucket User. And, sign-in to bitbucket was successful too through SourceTree's Accounts option. It is the subsequent git remote operations through SourceTree UI was suffering and now os-x Gmail synching too.
Then, I kept the password of Atlassian's user id(which is my Gmail id) to same as that of Gmail id. And, restarted the machine. Voila.. it all started working fine including Gmail synching and SourceTree.
Wondering if the password chosen for Atlassian account, which is the same as the Email-id used for its OAuth integration, did corrupt SourceTree's key-chain entries for HTTPS access. That sounds ridiculous and a critical bug. sigh!!!

How to resolve the issue in Jenkins

I am working on Jenkins by following below link and I am new to working on Jenkins.
https://blogs.msdn.microsoft.com/visualstudioalm/2016/05/27/continuous-deploymentdelivery-with-jenkins-and-vs-team-services/
Here I am facing the issue when I am installing the Jenkins its redirect to localhost URL and displaying the web page is like below figure and I am downloading the Jenkins from the below link. after redirect that its shows the Jenkins login and here I am informing before that I am not set the any logging details at any where in the Jenkins.
https://jenkins.io/
On Linux, default "admin" user password is available in /var/lib/jenkins/secrets/initialAdminPassword file.
I am not 100% sure about windows, you can check if secrets\initialAdminPassword file is available in Jenkins install directory. If yes, then try to login with credentials mentioned in this file

Jenkins 2.5 installation error (An error occurred during installation: Forbidden)

I have a fresh CentOS box, installed Tomcat 8.0 and Jenkins 2.5. After entering the secret key for a brand new installation, the next step Install suggested plugins or :Select plugins to install:. After clicking on Install suggested plugins I got an error saying
An error occurred during installation: Forbidden
I assume is related to folder permissions, the question is which one?
UPDATE: The jenkins log says
Found invalid crumb a711b93261896fb36a1d6ffbe163dca6. Will check remaining parameters for a valid one...
May 21, 2016 4:19:34 AM WARNING hudson.security.csrf.CrumbFilter doFilter
No valid crumb was included in request for /jenkins/administrativeMonitor/hudson.diagnosis.ReverseProxySetupMonitor/test. Returning 403.*
Thanks in advance.
If it's any help to anybody, I "fixed it" by restarting Jenkins http://jenkins:8080/restart, or whatever protocol, domain, and port. Then when I went back in it asked me for the secret key again, and then installed all the plugins successfully.
I have faced this problem before. It was because I was using a VPN. Once I closed the VPN, everything returned back to normal.
I was getting the same error when I was using Internet Explorer for JENKINS INSTALLATION on Windows 2019. I installed Chrome before trying again and the error went away!
I was facing this issue because I was using Internet Explorer. Switching the browser fixed the issue for me.
I faced this same issue, Alex's answer helped me.
Here's some addition to it:
I was running Jenkins on docker, so to restart it I had to do the following;
List all the running docker containers on the server:
docker container ls
Copy the container id for the Jenkins container
Restart the docker container for Jenkins using its id:
docker restart <jenkins-container-id>
Visit the URL for Jenkins again:
http://your-url:8080
Input your initial admin password, and then try setting up Jenkins again.
That's all.
I hope this helps

Version 7.1 (7B91b) and TFS Authentication [duplicate]

We are working on Xcode Project connected to our local TFS 2013 (Update 3) Server via TFS Provided Git Repository.
When we use older version of Xcode, we are successfully able to check-in the files and perform all other Git operations. We are also able to perform all Git Operations via command line Git.
The trouble is when we use latest version of Xcode - Version 7.1 (7B91b).
On entering valid credentials, we are getting error saying
Authentication failed because the user name or password was incorrect.
The same credentials / configuration work on older version of Xcode and Git Command Line Options.
To add more to the surprises, we are able to connect to github.com successfully.
We are able to reproduce issue on other systems too. Please provide us the best way to resolve this error.
For us it turned out to be because Xcode 7 does not support Windows Authentication. The solution described here solved it for us:
"This happens because XCode 7 doesn't support Windows Authentication.
I don't know why. It seems to be a common problem amongst users
because there are many posts about it in google.
To make it all work you should enable Basic Authentication in your IIS
TFS website on "tfs" virtual folder.
Be careful though because basic authentication sends your credentials
over network as plain text. You definitely must use SSL in this case."
(source)

Resources