<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic I am in a process of Connecting to X vendor and pull back the data needed from that X vendor. in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/i-am-in-a-process-of-connecting-to-x-vendor-and-pull-back-the/m-p/12663#M7435</link>
    <description>&lt;P&gt;For that we have shared our Azure IP addres (NO VPN or Corporate IP address Available as of now - still initial stages of the project) with X vendor, which is whitelisted now.&lt;/P&gt;&lt;P&gt; Now I am trying to setup the X vendor API in the databricks to lookup into the APi and fetch the response.&lt;/P&gt;&lt;P&gt;I have the url, credentials, .jks file, .pem file, certificate password.&lt;/P&gt;&lt;P&gt;with my below approach i am getting the error "&lt;B&gt;[SSL] PEM lib (_ssl.c:4046)&lt;/B&gt;"&lt;/P&gt;&lt;P&gt;Can someone help me if my approach is missing something..&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;import http.client
import json
import ssl
 
# Defining certificate related stuff and host of endpoint
certificate_file = "/dbfs/mnt/blob/Bronze/abc.112.2022.04.pem"
certificate_secret= "secretkey"
host = ' &lt;A href="https://efgh0112-dev.abc-connect.com'" target="test_blank"&gt;https://efgh0112-dev.abc-connect.com'&lt;/A&gt;;
user = "abc.id.efgh0112-dev.2022.04" 
passwd = "password" 
 
# Defining parts of the HTTP request
request_url='/link-ws/abc/postIdentity'
request_headers = {
    'Content-Type': 'application/json'
}
     
# Define the client certificate settings for https connection
context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
context.load_cert_chain(certfile=certificate_file, password=certificate_secret)
 
# Create a connection to submit HTTP requests
connection = http.client.HTTPSConnection(host, port=443, context=context)
 
# Use connection to submit a HTTP POST request
connection.request(method="POST", url=request_url, headers=request_headers, body=json.dumps(request_body_dict))
 
# Print the HTTP response from the IOT service endpoint
response = connection.getresponse()
print(response.status, response.reason)
data = response.read()
print(data)&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;</description>
    <pubDate>Mon, 25 Jul 2022 14:26:59 GMT</pubDate>
    <dc:creator>Sree_Patllola</dc:creator>
    <dc:date>2022-07-25T14:26:59Z</dc:date>
    <item>
      <title>I am in a process of Connecting to X vendor and pull back the data needed from that X vendor.</title>
      <link>https://community.databricks.com/t5/data-engineering/i-am-in-a-process-of-connecting-to-x-vendor-and-pull-back-the/m-p/12663#M7435</link>
      <description>&lt;P&gt;For that we have shared our Azure IP addres (NO VPN or Corporate IP address Available as of now - still initial stages of the project) with X vendor, which is whitelisted now.&lt;/P&gt;&lt;P&gt; Now I am trying to setup the X vendor API in the databricks to lookup into the APi and fetch the response.&lt;/P&gt;&lt;P&gt;I have the url, credentials, .jks file, .pem file, certificate password.&lt;/P&gt;&lt;P&gt;with my below approach i am getting the error "&lt;B&gt;[SSL] PEM lib (_ssl.c:4046)&lt;/B&gt;"&lt;/P&gt;&lt;P&gt;Can someone help me if my approach is missing something..&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;import http.client
import json
import ssl
 
# Defining certificate related stuff and host of endpoint
certificate_file = "/dbfs/mnt/blob/Bronze/abc.112.2022.04.pem"
certificate_secret= "secretkey"
host = ' &lt;A href="https://efgh0112-dev.abc-connect.com'" target="test_blank"&gt;https://efgh0112-dev.abc-connect.com'&lt;/A&gt;;
user = "abc.id.efgh0112-dev.2022.04" 
passwd = "password" 
 
# Defining parts of the HTTP request
request_url='/link-ws/abc/postIdentity'
request_headers = {
    'Content-Type': 'application/json'
}
     
# Define the client certificate settings for https connection
context = ssl.SSLContext(ssl.PROTOCOL_SSLv23)
context.load_cert_chain(certfile=certificate_file, password=certificate_secret)
 
# Create a connection to submit HTTP requests
connection = http.client.HTTPSConnection(host, port=443, context=context)
 
# Use connection to submit a HTTP POST request
connection.request(method="POST", url=request_url, headers=request_headers, body=json.dumps(request_body_dict))
 
# Print the HTTP response from the IOT service endpoint
response = connection.getresponse()
print(response.status, response.reason)
data = response.read()
print(data)&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Jul 2022 14:26:59 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/i-am-in-a-process-of-connecting-to-x-vendor-and-pull-back-the/m-p/12663#M7435</guid>
      <dc:creator>Sree_Patllola</dc:creator>
      <dc:date>2022-07-25T14:26:59Z</dc:date>
    </item>
  </channel>
</rss>

