401 error - Not able to update Jenkins plugins - jenkins-pipeline

we're getting the following error when trying to update the Jenkins plugins. we've proxy configured
"
Failure -
java.io.IOException: Server returned HTTP response code: 401 for URL: https://updates.jenkins.io/download/plugins/active-directory/2.26/active-directory.hpi"
enter image description here

401 status code means failed authorisation.
https://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.2
Try verifying your username password once.
https://updates.jenkins.io/download/plugins/active-directory/2.26/active-directory.hpi is globally accessible.
A simple wget from the jenkins machine will download the new plugin if the proxy is configured correctly.

Related

Could not GET '*/maven-metadata.xml'. Received status code 403 from server: Forbidden while publishing to AWS CodeArtifact

I have a maven repo set up in AWS CodeArtifact. I am using maven-publish plugin with Gradle to publish the artifacts. However, gradle exits with the following error -
Could not GET 'https://.../maven-metadata.xml'. Received status code 403 from server: Forbidden
This is because the AWS Role/User which is being used to authenticate to AWS CodeArtifact does not have the following permissions on the forbidden resource -
"codeartifact:Get*",
"codeartifact:Describe*",
"codeartifact:List*",
"codeartifact:ReadFromRepository"

Failed to build apache kudu because unable to connect to service.gradle.org

When trying to build kudu in my ec2, I got an error "HTTP/1.1 403 Forbidden". My connection was opened through a proxy. The domain that we are trying to connect to here is "service .gradle.org". This can be accessed through HTTPS. Here the build is run using the gradle wrapper jar (v6.8.3). Here, a 403 Forbidden error of the above type kept appearing. It lookes like the connection is trying to use HTTP instead of HTTPS.
This problem is not occurring when the build is run in an environment without a proxy
Build fail image

websocket._exceptions.WebSocketProxyException: failed CONNECT via proxy status: 403 when running in python anywhere

When trying to run my .py script it's showing the error
websocket._exceptions.WebSocketProxyException: failed CONNECT via proxy status: 403
I am using a module tvdatafeed which uses websocket. Please help to solve the issue. So that I can test my script on cloud
Free accounts cannot connect out to websocket endpoints.

Gradle : Unable to tunnel through proxy

I am trying to run a blank Flutter project behind a corporate proxy requiring basic authentication and self-signing HTTPS connections.
I added the necessary config in ~/.gradle/gradle.properties and in ~/.profile. I also imported my root certificate in $JAVA_HOME/jre/lib/security/cacerts and told Gradle to use it. I even tried this solution and set java.net.useSystemProxies=true in $JAVA_HOME/jre/lib/net.properties.
But, still, it doesn't build, and it asks for authentication.
flutter run
Launching lib/main.dart on Nexus 5 in debug mode...
Initializing gradle... 0.8s
Resolving dependencies...
* Error running Gradle:
Exit code 1 from: ~/GitLab/n.gendron/techno_store/android/gradlew app:properties:
java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 407 Proxy Authentication Required"
IOException: https://dl.google.com/android/repository/addons_list-3.xml
java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 407 Proxy Authentication Required"
IOException: https://dl.google.com/android/repository/addons_list-2.xml
java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 407 Proxy Authentication Required"
IOException: https://dl.google.com/android/repository/addons_list-1.xml
java.io.IOException: Unable to tunnel through proxy. Proxy returns "HTTP/1.1 407 Proxy Authentication Required"
Failed to download any source lists!
This guide helped me a lot trough this process, and this one helped me import the CA, but now I'm stuck.
Any idea?
You need in gradle/gradle.properties write:
# Project-wide Gradle settings.
...
systemProp.http.proxyHost=proxy.company.com
systemProp.http.proxyPort=443
systemProp.http.proxyUser=username
systemProp.http.proxyPassword=password
systemProp.http.auth.ntlm.domain=domain
systemProp.https.proxyHost=proxy.company.com
systemProp.https.proxyPort=443
systemProp.https.proxyUser=username
systemProp.https.proxyPassword=password
systemProp.https.auth.ntlm.domain=domain
...

Can not get gradle wrapper download the gradle distribution from local server

I have created a simple local file server with Tomcat 8 and stored the distributions of the gradle. I planned to use the gradle wrapper to download the gradle from the local file server, because it is slow to download from the official site here. I can download the file from the file server in browser, but I have met some problems. I use Tomcat and HTTP protocol. When I specify the URL and start to download, Android Studio gives me an error:
Exception in thread "main" java.lang.RuntimeException: java.io.IOException: Server returned HTTP response code: 500 for URL: http://yy.phiwifi.com/share/distributions/gradle-2.11-all.zip
at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAccessManager.java:78)
at org.gradle.wrapper.Install.createDist(Install.java:47)
at org.gradle.wrapper.WrapperExecutor.execute(WrapperExecutor.java:129)
at org.gradle.wrapper.GradleWrapperMain.main(GradleWrapperMain.java:48)
Caused by: java.io.IOException: Server returned HTTP response code: 500 for URL: http://yy.phiwifi.com/share/distributions/gradle-2.11-all.zip
at sun.net.www.protocol.http.HttpURLConnection.getInputStream0(HttpURLConnection.java:1840)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1441)
at org.gradle.wrapper.Download.downloadInternal(Download.java:59)
at org.gradle.wrapper.Download.download(Download.java:45)
at org.gradle.wrapper.Install$1.call(Install.java:60)
at org.gradle.wrapper.Install$1.call(Install.java:47)
at org.gradle.wrapper.ExclusiveFileAccessManager.access(ExclusiveFileAccessManager.java:65)
... 3 more
I don't know the reason, I thought maybe it is the protocol, I should use https, so I change the protocol and tried it again, but it still not working. Can anyone help me?

Resources