{"action":"created","issue":{"url":"https://api.github.com/repos/aws/aws-sdk-java/issues/823","repository_url":"https://api.github.com/repos/aws/aws-sdk-java","labels_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/823/labels{/name}","comments_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/823/comments","events_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/823/events","html_url":"https://github.com/aws/aws-sdk-java/issues/823","id":172848226,"number":823,"title":"PKIX SSL error while connecting to SQS ","user":{"login":"mukteshkrmishra","id":10970467,"avatar_url":"https://avatars.githubusercontent.com/u/10970467?v=3","gravatar_id":"","url":"https://api.github.com/users/mukteshkrmishra","html_url":"https://github.com/mukteshkrmishra","followers_url":"https://api.github.com/users/mukteshkrmishra/followers","following_url":"https://api.github.com/users/mukteshkrmishra/following{/other_user}","gists_url":"https://api.github.com/users/mukteshkrmishra/gists{/gist_id}","starred_url":"https://api.github.com/users/mukteshkrmishra/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mukteshkrmishra/subscriptions","organizations_url":"https://api.github.com/users/mukteshkrmishra/orgs","repos_url":"https://api.github.com/users/mukteshkrmishra/repos","events_url":"https://api.github.com/users/mukteshkrmishra/events{/privacy}","received_events_url":"https://api.github.com/users/mukteshkrmishra/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/aws/aws-sdk-java/labels/waiting-reply","name":"waiting-reply","color":"207de5"}],"state":"closed","locked":false,"assignee":{"login":"shorea","id":11096681,"avatar_url":"https://avatars.githubusercontent.com/u/11096681?v=3","gravatar_id":"","url":"https://api.github.com/users/shorea","html_url":"https://github.com/shorea","followers_url":"https://api.github.com/users/shorea/followers","following_url":"https://api.github.com/users/shorea/following{/other_user}","gists_url":"https://api.github.com/users/shorea/gists{/gist_id}","starred_url":"https://api.github.com/users/shorea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shorea/subscriptions","organizations_url":"https://api.github.com/users/shorea/orgs","repos_url":"https://api.github.com/users/shorea/repos","events_url":"https://api.github.com/users/shorea/events{/privacy}","received_events_url":"https://api.github.com/users/shorea/received_events","type":"User","site_admin":false},"assignees":[{"login":"shorea","id":11096681,"avatar_url":"https://avatars.githubusercontent.com/u/11096681?v=3","gravatar_id":"","url":"https://api.github.com/users/shorea","html_url":"https://github.com/shorea","followers_url":"https://api.github.com/users/shorea/followers","following_url":"https://api.github.com/users/shorea/following{/other_user}","gists_url":"https://api.github.com/users/shorea/gists{/gist_id}","starred_url":"https://api.github.com/users/shorea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shorea/subscriptions","organizations_url":"https://api.github.com/users/shorea/orgs","repos_url":"https://api.github.com/users/shorea/repos","events_url":"https://api.github.com/users/shorea/events{/privacy}","received_events_url":"https://api.github.com/users/shorea/received_events","type":"User","site_admin":false}],"milestone":null,"comments":2,"created_at":"2016-08-24T02:02:17Z","updated_at":"2016-08-30T15:02:27Z","closed_at":"2016-08-30T15:02:26Z","body":"HI,\r\n\r\nI have a queue in AWS and while trying to connect it and pushing some message programmatically (using Java SDK) I am getting following error:\r\n\r\nNEGOTIATE authentication error: Invalid name provided (Mechanism level: KrbException: Cannot locate default realm)\r\n\r\n[INFO] [talledLocalContainer] Caused by: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target\r\n\r\nI tried adding AWS public certificate also in JDK keystore's cacaerts using Keystore import command. But still same exception. Can you please help.\r\nkeytool -import -alias awscert -keystore /Library/Java/JavaVirtualMachines/jdk1.8.0_91.jdk/Contents/Home/jre/lib/security/cacerts -file /path/awspubliccert.pem\r\n\r\n\r\n[INFO] [talledLocalContainer] com.amazonaws.AmazonClientException: Unable to execute HTTP request: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target\r\n[INFO] [talledLocalContainer] \tat com.amazonaws.http.AmazonHttpClient.executeHelper(AmazonHttpClient.java:723) ~[aws-java-sdk-1.11.27.jar:?]\r\n[INFO] [talledLocalContainer] \tat com.amazonaws.http.AmazonHttpClient.doExecute(AmazonHttpClient.java:465) ~[aws-java-sdk-1.11.27.jar:?]\r\n[INFO] [talledLocalContainer] \tat com.amazonaws.http.AmazonHttpClient.executeWithTimer(AmazonHttpClient.java:427) ~[aws-java-sdk-1.11.27.jar:?]\r\n[INFO] [talledLocalContainer] \tat com.amazonaws.http.AmazonHttpClient.execute(AmazonHttpClient.java:376) ~[aws-java-sdk-1.11.27.jar:?]\r\n[INFO] [talledLocalContainer] \tat com.amazonaws.services.sqs.AmazonSQSClient.doInvoke(AmazonSQSClient.java:1750) ~[aws-java-sdk-1.11.27.jar:?]\r\n[INFO] [talledLocalContainer] \tat com.amazonaws.services.sqs.AmazonSQSClient.invoke(AmazonSQSClient.java:1720) ~[aws-java-sdk-1.11.27.jar:?]\r\n[INFO] [talledLocalContainer] \tat com.amazonaws.services.sqs.AmazonSQSClient.sendMessageBatch(AmazonSQSClient.java:1598) ~[aws-java-sdk-1.11.27.jar:?]\r\n\r\n[INFO] [talledLocalContainer] Caused by: javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.Alerts.getSSLException(Alerts.java:192) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.SSLSocketImpl.fatal(SSLSocketImpl.java:1949) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.Handshaker.fatalSE(Handshaker.java:302) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.Handshaker.fatalSE(Handshaker.java:296) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.ClientHandshaker.serverCertificate(ClientHandshaker.java:1509) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.ClientHandshaker.processMessage(ClientHandshaker.java:216) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.Handshaker.processLoop(Handshaker.java:979) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.Handshaker.process_record(Handshaker.java:914) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1062) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1375) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1403) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1387) ~[?:1.8.0_74]\r\n[INFO] [talledLocalContainer] \tat org.apache.http.conn.ssl.SSLConnectionSocketFactory.createLayeredSocket(SSLConnectionSocketFactory.java:394) ~[httpclient-4.5.1.jar:4.5.1]\r\n[INFO] [talledLocalContainer] \tat org.apache.http.impl.conn.DefaultHttpClientConnectionOperator.upgrade(DefaultHttpClientConnectionOperator.java:185) ~[httpclient-4.5.1.jar:4.5.1]\r\n\r\n "},"comment":{"url":"https://api.github.com/repos/aws/aws-sdk-java/issues/comments/243469961","html_url":"https://github.com/aws/aws-sdk-java/issues/823#issuecomment-243469961","issue_url":"https://api.github.com/repos/aws/aws-sdk-java/issues/823","id":243469961,"user":{"login":"shorea","id":11096681,"avatar_url":"https://avatars.githubusercontent.com/u/11096681?v=3","gravatar_id":"","url":"https://api.github.com/users/shorea","html_url":"https://github.com/shorea","followers_url":"https://api.github.com/users/shorea/followers","following_url":"https://api.github.com/users/shorea/following{/other_user}","gists_url":"https://api.github.com/users/shorea/gists{/gist_id}","starred_url":"https://api.github.com/users/shorea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shorea/subscriptions","organizations_url":"https://api.github.com/users/shorea/orgs","repos_url":"https://api.github.com/users/shorea/repos","events_url":"https://api.github.com/users/shorea/events{/privacy}","received_events_url":"https://api.github.com/users/shorea/received_events","type":"User","site_admin":false},"created_at":"2016-08-30T15:02:26Z","updated_at":"2016-08-30T15:02:26Z","body":"Closing issue. Feel free to reopen if problem persists."}}
{"actor":{"display_login":"shorea"}}