react-native-pdf icon indicating copy to clipboard operation
react-native-pdf copied to clipboard

I have check Multiple time of different solution but..

Open krsaurabhmca opened this issue 1 year ago • 2 comments

[Error: ReactNativeBlobUtil request error: java.lang.IllegalStateException: Use of own trust manager but none definedjava.lang.IllegalStateException: Use of own trust manager but none defined] LOG [Error: ReactNativeBlobUtil request error: java.lang.IllegalStateException: Use of own trust manager but none definedjava.lang.IllegalStateException: Use of own trust manager but none defined]

krsaurabhmca avatar Sep 28 '24 00:09 krsaurabhmca

for android use this

<Pdf
  trustAllCerts={Platform.OS === 'ios'} // Only apply this for iOS
  style={styles.viewer}
  source={{
    uri: currentUrl,
    headers: { Cookie: authCookie },
  }}
  onLoadProgress={(progress) => {
    console.log('Loading progress:', progress);
  }}
  onLoadComplete={(pageCount) => {
    console.log('PDF loaded, total pages:', pageCount);
  }}
/>

rajivchaulagain avatar Oct 22 '24 08:10 rajivchaulagain

Good morning. I have a question regarding security: how reliable is it to set trustAllCerts to false in Android? I need to implement this library in an enterprise app, and if this prop introduces vulnerabilities, I should consider switching to another solution. In threads related to this topic, everyone suggests this as a solution, but no one explains if it could cause security issues.

GabrielBermudez avatar Nov 14 '24 14:11 GabrielBermudez

@GabrielBermudez this must be helpful for u https://github.com/RonRadtke/react-native-blob-util#self-signed-ssl-server

rajivchaulagain avatar Nov 14 '24 14:11 rajivchaulagain