<?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 Re: getting an InitialContext from a pure Java client in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104279#M981439</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Boris,&lt;/P&gt;&lt;P&gt;Can you kindly share the solution?&lt;/P&gt;&lt;P&gt;Others may have the same problem.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ballock.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 03 Sep 2008 15:10:24 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-09-03T15:10:24Z</dc:date>
    <item>
      <title>getting an InitialContext from a pure Java client</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104276#M981436</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi All,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;we have a NW CE 7.1 SP3 installation and I'm trying to get an InitialContext from a pure Java Client.&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
    public static void main(String[] args)
    {
        Hashtable env = new Hashtable();
        env.put(
            Context.INITIAL_CONTEXT_FACTORY,
            "com.sap.engine.services.jndi.InitialContextFactoryImpl");
        env.put(Context.PROVIDER_URL, "ttx1345:50004");
        env.put(Context.SECURITY_PRINCIPAL, "Administrator");
        env.put(Context.SECURITY_CREDENTIALS, "*****");
        Context context = null;
        try
        {
            context = new InitialContext(env);
        }
        catch (Exception e)
        {
            e.printStackTrace();
        }
        finally
        {
            if (context != null)
            {
                try
                {
                    context.close();
                }
                catch (NamingException e1)
                {
                    e1.printStackTrace();
                }
            }
        }
    }
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;This works fine for the Netweaver 2004 J2EE Engine, but now I get the following error: com.sap.engine.services.jndi.persistent.exceptions.SecurityException: Cannot get InitialContext, operation is not allowed.&lt;/P&gt;&lt;P&gt;The User has the jndi_get_initial_context Action assigned in UME. Logon with WEB Application is no problem and works fine for this User.&lt;/P&gt;&lt;P&gt;In Netweaver 2004 the component service.naming has an security role  jndi_get_initial_context assigned. It was configured within the Visual Administrator security provider-&amp;gt;Components-&amp;gt;Security Roles.&lt;/P&gt;&lt;P&gt;In the WEB based SAP NetWeaver Administrator I only found the component service.naming under the topic Authentication. But here you can only configure the Login Module Stack.&lt;/P&gt;&lt;P&gt;In Netweaver 2004 this was done in Visual Administrator security provider-&amp;gt;component-&amp;gt;Authentication.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So, does anyone know how/where to configure security roles for the component service.naming?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Boris&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Boris Fierlings on Jul 10, 2008 4:14 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 10 Jul 2008 14:13:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104276#M981436</guid>
      <dc:creator>boris_fierlings</dc:creator>
      <dc:date>2008-07-10T14:13:12Z</dc:date>
    </item>
    <item>
      <title>Re: getting an InitialContext from a pure Java client</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104277#M981437</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;found the solution myself&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Jul 2008 11:18:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104277#M981437</guid>
      <dc:creator>boris_fierlings</dc:creator>
      <dc:date>2008-07-14T11:18:29Z</dc:date>
    </item>
    <item>
      <title>Re: getting an InitialContext from a pure Java client</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104278#M981438</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;Could you please share how did you find the solution and please let us know the specific scenario.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Srihari&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 Jul 2008 05:43:43 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104278#M981438</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-07-15T05:43:43Z</dc:date>
    </item>
    <item>
      <title>Re: getting an InitialContext from a pure Java client</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104279#M981439</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Boris,&lt;/P&gt;&lt;P&gt;Can you kindly share the solution?&lt;/P&gt;&lt;P&gt;Others may have the same problem.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ballock.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 03 Sep 2008 15:10:24 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-an-initialcontext-from-a-pure-java-client/m-p/4104279#M981439</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-09-03T15:10:24Z</dc:date>
    </item>
  </channel>
</rss>

