Skip to Content
avatar image
Former Member

JCO3 and SSO

Hi everyone,

how is the proposed way to using Java Connector 3 Client with Single Sign-On for the two scenarios:

- Using SAP Logon Ticket

- Providing username/password programmatically (e.g. after getting them from the portal's user mapping)

There is a property jco.client.mysapsso2 in DestinationDataProvider. Do I have to specify a new JCoDestination for each user (session)? This is not the way I would expect it to work, for basically I would like to create one destination for each R/3 system I access.

Thanks in advance!


Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Best Answer
    avatar image
    Former Member
    Sep 30, 2008 at 12:38 PM


    you could write and register your own DestinationDataProvider and overwrite the method getDestinationProperties(String destinationName)

    you could then define some sort of mapping - e.g. adding the sso ticket to the destinationName and then in the method return the properties with the jco.client.mysapsso2 with the sso ticket

    could look like this


    regards franz

    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Apr 01, 2009 at 08:29 PM

    In the meantime I found out how to do it right:

    // After getting the desired destination, create a custom destination for it
    JCoDestination destination = JCoEnvironment.getDestination( "<DestinationName>" );
    JCoCustomDestination custDest = destination.createCustomDestination();
    // From the custom destination you can get and manipulate the corresponding UserData object
    UserData data = custDest.getUserLogonData();
    // On this object you can set the desired fields (see Javadoc for UserData for more information)
    data.setAliasUser( ... );
    data.setClient( ... );
    data.setLanguage( ... );
    data.setPassword( ... );
    data.setSSOTicket( ... );
    data.setUser( ... );
    data.setX509Certificate( ... );
    // Then, use the custom destination to do things
    JCoContext.begin( custDest );
    JCoContext.end( custDest );

    I only tried it using a different user/password combination than configured and it worked. Didn't yet try with SSO.

    Note that JCo creates one physical connection to the R/3 system when getting the destination and a second when creating the custom destination.

    Edited by: Carsten Erker on Apr 1, 2009 10:32 PM

    Add comment
    10|10000 characters needed characters exceeded