javax.net.ssl.SSLException: Received fatal alert: bad_record_mac

JIRA | Erik Hetzner | 4 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Not exactly a heritrix bug per se, but I wanted to track this issue. We are unable to crawl the url: https://netfiles.uiuc.edu/akachi2/home We get the following error: {code} SSLException@HTTP javax.net.ssl.SSLException: Received fatal alert: bad_record_mac at sun.security.ssl.Alerts.getSSLException(Alerts.java:208) at sun.security.ssl.Alerts.getSSLException(Alerts.java:154) at sun.security.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1977) at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1093) at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1328) at sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:702) at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:122) at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82) at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140) at org.archive.io.RecordingOutputStream.flush(RecordingOutputStream.java:389) at org.apache.commons.httpclient.HttpConnection.flushRequestOutputStream(HttpConnection.java:860) at org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:1984) at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1000) at org.archive.httpclient.HttpRecorderGetMethod.execute(HttpRecorderGetMethod.java:116) at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398) at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171) at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397) at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346) at org.archive.crawler.fetcher.FetchHTTP.innerProcess(FetchHTTP.java:497) at org.archive.crawler.framework.Processor.process(Processor.java:112) at org.archive.crawler.framework.ToeThread.processCrawlUri(ToeThread.java:302) at org.archive.crawler.framework.ToeThread.run(ToeThread.java:151) {code} This seems to be more a Java issue than a heritrix issue; I am unable to get the file using the tika-app jar: {code} ❤ java -jar tika-app-1.2.jar https://netfiles.uiuc.edu/akachi2/home Exception in thread "main" javax.net.ssl.SSLException: Received fatal alert: bad_record_mac at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1491) at java.security.AccessController.doPrivileged(Native Method) at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1485) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1139) at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:234) at org.apache.tika.io.TikaInputStream.get(TikaInputStream.java:395) at org.apache.tika.cli.TikaCLI.process(TikaCLI.java:412) at org.apache.tika.cli.TikaCLI.main(TikaCLI.java:108) Caused by: javax.net.ssl.SSLException: Received fatal alert: bad_record_mac at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1720) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:954) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1138) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1165) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1149) at sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:434) at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:166) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1172) at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:2308) at java.net.URLConnection.getContentType(URLConnection.java:485) at sun.net.www.protocol.https.HttpsURLConnectionImpl.getContentType(HttpsURLConnectionImpl.java:382) at org.apache.tika.io.TikaInputStream.get(TikaInputStream.java:380) ... 2 more {code} I don't know if there is anything to be done here, but I thought I'd report the issue.

    JIRA | 4 years ago | Erik Hetzner
    javax.net.ssl.SSLException: Received fatal alert: bad_record_mac
  2. 0

    Not exactly a heritrix bug per se, but I wanted to track this issue. We are unable to crawl the url: https://netfiles.uiuc.edu/akachi2/home We get the following error: {code} SSLException@HTTP javax.net.ssl.SSLException: Received fatal alert: bad_record_mac at sun.security.ssl.Alerts.getSSLException(Alerts.java:208) at sun.security.ssl.Alerts.getSSLException(Alerts.java:154) at sun.security.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1977) at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1093) at sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1328) at sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:702) at sun.security.ssl.AppOutputStream.write(AppOutputStream.java:122) at java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82) at java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140) at org.archive.io.RecordingOutputStream.flush(RecordingOutputStream.java:389) at org.apache.commons.httpclient.HttpConnection.flushRequestOutputStream(HttpConnection.java:860) at org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:1984) at org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1000) at org.archive.httpclient.HttpRecorderGetMethod.execute(HttpRecorderGetMethod.java:116) at org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398) at org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171) at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397) at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346) at org.archive.crawler.fetcher.FetchHTTP.innerProcess(FetchHTTP.java:497) at org.archive.crawler.framework.Processor.process(Processor.java:112) at org.archive.crawler.framework.ToeThread.processCrawlUri(ToeThread.java:302) at org.archive.crawler.framework.ToeThread.run(ToeThread.java:151) {code} This seems to be more a Java issue than a heritrix issue; I am unable to get the file using the tika-app jar: {code} ❤ java -jar tika-app-1.2.jar https://netfiles.uiuc.edu/akachi2/home Exception in thread "main" javax.net.ssl.SSLException: Received fatal alert: bad_record_mac at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) at java.lang.reflect.Constructor.newInstance(Constructor.java:513) at sun.net.www.protocol.http.HttpURLConnection$6.run(HttpURLConnection.java:1491) at java.security.AccessController.doPrivileged(Native Method) at sun.net.www.protocol.http.HttpURLConnection.getChainedException(HttpURLConnection.java:1485) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1139) at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:234) at org.apache.tika.io.TikaInputStream.get(TikaInputStream.java:395) at org.apache.tika.cli.TikaCLI.process(TikaCLI.java:412) at org.apache.tika.cli.TikaCLI.main(TikaCLI.java:108) Caused by: javax.net.ssl.SSLException: Received fatal alert: bad_record_mac at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:190) at com.sun.net.ssl.internal.ssl.Alerts.getSSLException(Alerts.java:136) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1720) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:954) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1138) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1165) at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:1149) at sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:434) at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:166) at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLConnection.java:1172) at sun.net.www.protocol.http.HttpURLConnection.getHeaderField(HttpURLConnection.java:2308) at java.net.URLConnection.getContentType(URLConnection.java:485) at sun.net.www.protocol.https.HttpsURLConnectionImpl.getContentType(HttpsURLConnectionImpl.java:382) at org.apache.tika.io.TikaInputStream.get(TikaInputStream.java:380) ... 2 more {code} I don't know if there is anything to be done here, but I thought I'd report the issue.

    JIRA | 4 years ago | Erik Hetzner
    javax.net.ssl.SSLException: Received fatal alert: bad_record_mac
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    CalDAV calendar server SSL not working

    Stack Overflow | 3 years ago | user3798046
    javax.net.ssl.SSLException: Received fatal alert: bad_record_mac
  5. 0

    IntelliJ Idea doesn't work properly with svn update

    Stack Overflow | 4 years ago | Raman
    javax.net.ssl.SSLException: Received fatal alert: unexpected_message

  1. Andreas Häber 6 times, last 5 months ago
15 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. javax.net.ssl.SSLException

    Received fatal alert: bad_record_mac

    at sun.security.ssl.Alerts.getSSLException()
  2. Java JSSE
    AppOutputStream.write
    1. sun.security.ssl.Alerts.getSSLException(Alerts.java:208)
    2. sun.security.ssl.Alerts.getSSLException(Alerts.java:154)
    3. sun.security.ssl.SSLSocketImpl.recvAlert(SSLSocketImpl.java:1977)
    4. sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:1093)
    5. sun.security.ssl.SSLSocketImpl.performInitialHandshake(SSLSocketImpl.java:1328)
    6. sun.security.ssl.SSLSocketImpl.writeRecord(SSLSocketImpl.java:702)
    7. sun.security.ssl.AppOutputStream.write(AppOutputStream.java:122)
    7 frames
  3. Java RT
    BufferedOutputStream.flush
    1. java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:82)
    2. java.io.BufferedOutputStream.flush(BufferedOutputStream.java:140)
    2 frames
  4. webarchive-commons
    RecordingOutputStream.flush
    1. org.archive.io.RecordingOutputStream.flush(RecordingOutputStream.java:389)
    1 frame
  5. HttpClient
    HttpMethodBase.execute
    1. org.apache.commons.httpclient.HttpConnection.flushRequestOutputStream(HttpConnection.java:860)
    2. org.apache.commons.httpclient.HttpMethodBase.writeRequest(HttpMethodBase.java:1984)
    3. org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:1000)
    3 frames
  6. webarchive-commons
    HttpRecorderGetMethod.execute
    1. org.archive.httpclient.HttpRecorderGetMethod.execute(HttpRecorderGetMethod.java:116)
    1 frame
  7. HttpClient
    HttpClient.executeMethod
    1. org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:398)
    2. org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:171)
    3. org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
    4. org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346)
    4 frames
  8. org.archive.crawler
    ToeThread.run
    1. org.archive.crawler.fetcher.FetchHTTP.innerProcess(FetchHTTP.java:497)
    2. org.archive.crawler.framework.Processor.process(Processor.java:112)
    3. org.archive.crawler.framework.ToeThread.processCrawlUri(ToeThread.java:302)
    4. org.archive.crawler.framework.ToeThread.run(ToeThread.java:151)
    4 frames