<?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>Question Re: How to Access the portal keystore using java code in Technology Q&amp;A</title>
    <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426108#M1702311</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roy,&lt;/P&gt;&lt;P&gt; I'm also searching for the APIs available in SAP Netweaver to access Keystore so that I can exchange certificates with another application. Can you please point me to the correct APIs? Also I like to know the DCs I need to add as dependencies (Used DC) to access those APIs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Dipankar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 03 Dec 2008 09:44:18 GMT</pubDate>
    <dc:creator>former_member4529</dc:creator>
    <dc:date>2008-12-03T09:44:18Z</dc:date>
    <item>
      <title>How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaq-p/4426104</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've exchanged certificates with a third party portal and I am now interested in sending it a message digest and a signature using PKI approach implemented through Java APIs.&lt;/P&gt;&lt;P&gt;in PKI the signature is generated from the public key in the keystore.&lt;/P&gt;&lt;P&gt;Where on the filesystem can I find SAP's keystore that holds the portal's public key and how can I access it using java code (not via Visual Admin)?&lt;/P&gt;&lt;P&gt;I have already read [this post|&lt;A class="jive_macro jive_macro_thread" href="https://community.sap.com/" __jive_macro_name="thread" modifiedtitle="true" __default_attr="6737"&gt;&lt;/A&gt;; but it doesn't really answer my question.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rgds,&lt;/P&gt;&lt;P&gt;Roy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 11 Sep 2008 13:21:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaq-p/4426104</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-11T13:21:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426105#M1702308</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Anyone...?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2008 15:08:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426105#M1702308</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-12T15:08:38Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426106#M1702309</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Not Sure buddy if this helps &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive_macro jive_macro_thread" href="https://community.sap.com/" __jive_macro_name="thread" modifiedtitle="true" __default_attr="135080"&gt;&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Pankaj Prasoon&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2008 19:52:31 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426106#M1702309</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-12T19:52:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426107#M1702310</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Nope doesn't help, this deals with certificate import problem, I'm past that stage. We've exchanged certificates successfully now I want to send the other side a message. How do I get the public key to encrypt it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 12 Sep 2008 21:07:40 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426107#M1702310</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-12T21:07:40Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426108#M1702311</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roy,&lt;/P&gt;&lt;P&gt; I'm also searching for the APIs available in SAP Netweaver to access Keystore so that I can exchange certificates with another application. Can you please point me to the correct APIs? Also I like to know the DCs I need to add as dependencies (Used DC) to access those APIs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance,&lt;/P&gt;&lt;P&gt;Dipankar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Dec 2008 09:44:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426108#M1702311</guid>
      <dc:creator>former_member4529</dc:creator>
      <dc:date>2008-12-03T09:44:18Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426109#M1702312</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Dipankar,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Unfortunately SAP does not have any documentation for this API but luckily all you need is to retrieve the keystore object from the JNDI registry and once you got it, it is plain Java API which is documented.&lt;/P&gt;&lt;P&gt;Here is a sample from the code I am using now and is working.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
InitialContext ctx = new InitialContext();
KeystoreManager manager = (KeystoreManager) ctx.lookup("keystore");
KeyStore keyStore = manager.getKeystore(&amp;lt;the view name you want to retrieve&amp;gt;);

// Now let's get a certificate from that view...
Certificate cert = keyStore.getCertificate(&amp;lt;certID&amp;gt;);

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Make sure that your application has got authorisations to access this view.&lt;/P&gt;&lt;P&gt;You can control that access in the Key Storage service on VA -&amp;gt; Security -&amp;gt; and grant your code access to the relevant View.&lt;/P&gt;&lt;P&gt;You will need these DCs: IAIKSecurity and com.sap.security.api.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps,&lt;/P&gt;&lt;P&gt;Roy&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Roy Cohen on Dec 3, 2008 11:52 AM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Dec 2008 09:51:04 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426109#M1702312</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-03T09:51:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426110#M1702313</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roy,&lt;/P&gt;&lt;P&gt; Thanks for the quick reply. I'm trying to use the same API you mentioned. But I'm facing the problem that &lt;STRONG&gt;KeystoreManager&lt;/STRONG&gt; in the statement &lt;EM&gt;KeystoreManager manager = (KeystoreManager) ctx.lookup("keystore");&lt;/EM&gt; is not getting resolved due to missing import. &lt;/P&gt;&lt;P&gt; As you mentioned I can't find any DC as com.sap.security.api but there is a DC available as com.sap.security.api.sda which I've added in Used DC. Also I've added IAIKSecurity as well, as Used DC from SAP-JEE SC. I'm using Local Development in Netweaver 7.0 SP11. Can you please help?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Dipankar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Dec 2008 10:07:53 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426110#M1702313</guid>
      <dc:creator>former_member4529</dc:creator>
      <dc:date>2008-12-03T10:07:53Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426111#M1702314</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What don't you use jar locator then?&lt;/P&gt;&lt;P&gt;KeystoreManager in either of these locations:&lt;/P&gt;&lt;P&gt;plugins\com.sap.tc.ap_2.0.0\comp\SAP-JEE\DCs\sap.com\com.sap.engine.client.lib\_comp\gen\default\public\default\lib\java\sapj2eeclient.jar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;\plugins\com.sap.tc.ap_2.0.0\comp\SAP-JEE\DCs\sap.com\com.sap.engine.deploy.online\_comp\gen\default\public\default\lib\java\sapj2eenginedeploy.jar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;\plugins\com.sap.tc.ap_2.0.0\comp\SAP-JEE\DCs\sap.com\keystore_api\_comp\gen\default\public\default\lib\java\keystore_api.jar&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or, take keystore_api.jar from the server and use it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Roy&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Roy Cohen on Dec 3, 2008 12:13 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Dec 2008 10:12:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426111#M1702314</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-03T10:12:56Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426112#M1702315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roy,&lt;/P&gt;&lt;P&gt; Thanks a lot for your help! Now we can successfully build the project. But I also need to save a new certificate in the Keystore using the APIs. Is it possible? If so how? I can't find any createCertificate() method on the Keystore object.&lt;/P&gt;&lt;P&gt; I'll really appreciate your help!&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Dipankar&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Dec 2008 07:01:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426112#M1702315</guid>
      <dc:creator>former_member4529</dc:creator>
      <dc:date>2008-12-04T07:01:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to Access the portal keystore using java code</title>
      <link>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426113#M1702316</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Dipankar,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;That wasn't part of my to do list so you'll have to dig the API yourself... &lt;SPAN __jive_emoticon_name="happy"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Rgds,&lt;/P&gt;&lt;P&gt;Roy&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 04 Dec 2008 09:33:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/technology-q-a/how-to-access-the-portal-keystore-using-java-code/qaa-p/4426113#M1702316</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-12-04T09:33:58Z</dc:date>
    </item>
  </channel>
</rss>

