Custom Role Maper example

Hi All,
Can any one provide sample Role mappers example?
I am basically ADF developer,i am not fully aware of weblogic API.
it would be great if you guys tell me how to start or if you provide some sample links.
appreciate you help
Thanks
KT

reply to your thread.
custome role maper example

Similar Messages

  • Problem with role mapping in custom login module

    Hi all,
    I have developed custom login modules. They don't use the default user store but own data tables holding the necessary user information.
    Login works fine. But there is one big problem: Only those users that exist with the same user-id in the default user store get roles assigned to it. Whicht leads to 403-errors in my web application.
    Now, this is weired because a user with id 'Susi' has completely different passwords in my custom tables and in the user store, therefore it shouldn't be possible to authenticate 'Susi' against the default user management.
    Next thing is, I don't use the default login modules at all. So why does the application validates against the user store?
    I thought a source of the  problem might be that I don't set the roles correctly. I set the roles as a principal to the subject. I have chosen the role based mapping  in the web-engine.xml and mapped all my custom roles to the server role 'guests'.
    Could anybody think of a solution to this problem ?
    Thanks,  Astrid

    Astrid,
    Sorry to go off-topic on your post...but I have a question in relation to how you deploy your login module. Do you deploy the login module with your application ? I've developed a login module that I would like to deploy by itself, I currently deploy it with the calculator example and it works fine like this, but I need to deploy it by itself. Any tips you can give would be greatly appreciated.
    I've tried to use the deploytool and deploy the module as a library...but I get a "cannot  load a login module" in the logs when authenticating a user.

  • Example of a custom field mapping?

    Ok, I admit it I am struggling here. I have simplified my example from
    what I actually have.
    I have a table that models a flat hierarchy
    ID | START_DATE | END_DATE | CLASSNAME | FIELD1 | FIELD2 | ...
    one of the objects in my hiearchy (CashFlow) has a field that is in fact
    another object called DatePeriod that contains two fields startDate and
    endDate.
    I understand that what I am trying to do is embed the DatePeriod object
    inside of the larger object when it get's persisted.
    I have the following metadata set-up
    <class name="CashFlow" persistence-capable-superclass="InstrumentFlow">
    <extension vendor-name="kodo" key="table" value="INSTRUMENT_FLOW"/>
    <extension vendor-name="kodo" key="pk-column" value="ID"/>
    <extension vendor-name="kodo" key="class-column" value="none"/>
    <extension vendor-name="kodo" key="lock-column" value="none"/>
    <field name="accrualPeriod" embedded="true"/>
    </class>
    and for my DatePeriod object
    <class name="DatePeriod">
    <extension vendor-name="kodo" key="table" value="INSTRUMENT_FLOW"/>
    <extension vendor-name="kodo" key="pk-column" value="ID"/>
    <extension vendor-name="kodo" key="lock-column" value="none"/>
    <extension vendor-name="kodo" key="class-column" value="none"/>
    <field name="startDate">
    <extension vendor-name="kodo" key="data-column" value="START_DATE"/>
    </field>
    <field name="endDate">
    <extension vendor-name="kodo" key="data-column" value="END_DATE"/>
    </field>
    </class>
    Every time I try to fetch a CashFlow object I get an error as KODO is
    trying to select the column 'ACCRUALPERIODX.'
    What am I doing wrong? Do I need to use a custom field mapping? If so
    where is the documentation to help me write a custom field mapping?
    A second question would be what happens if the DatePeriod object is used
    in a couple of places, I don't want to tie it's persistence to the
    INSTRUMENT_FLOW table.
    All help gratefully received
    Cheers
    Matt

    As you suspect, Kodo 2.x does not support embedded class mappings. Kodo
    3.0 will support embedded mappings.
    In the meantime, you can create a custom mapping, but unfortunately our
    documentation for custom mappings is lacking right now. Given how simple
    your DatePeriod object is, you're probably better off with something
    simpler (and as a bonus, less bound to Kodo):
    Just make your DatePeriod class and the field that holds the DatePeriod
    instance non-persistent. In the class that has the (now non-persistent)
    DatePeriod field, add two new persistent fields for the startDate and
    endDate. Then just use internal logic to construct the DatePeriod from
    the startDate and endDate. You can do this using the
    javax.jdo.InstanceCallbacks methods, or just do the logic in your setter
    and getter methods for the DatePeriod.

  • _Is there a way to make custom keyboard mapping a default?

    _Is there a way to make custom keyboard mapping a default?
    What I mean is, for example, I want to disable <command> S for saving (so I don't accidentally hit it).
    Thanks!
    Hugh

    Edit>Keyboard Shortcuts Make the changes you want to the shortcuts and save with a new name. In the dropdown at the top choose your new set and close. Quit and restart to seal the deal.

  • Is it possible to modify the tag structure tree and the role map via scripting?

    We use unstructured FrameMaker to produce training materials which we distribute as tagged PDF to meet accessibility requirements.
    When FrameMaker creates a tagged PDF, it does a fairly good job of populating the structure based on the PDF setup information for the paragraph formats in the FrameMaker documents. However, there are some limitations in the support that FrameMaker provides. For example, almost all paragraphs are assigned to the P role even if they are headings and should be mapped to H1-H6.
    We want to be able to easily post-process a PDF that has been generated from FrameMaker to fix some of the tag structure issues (including tag names and the role map) so that the PDF will provide the optimum experience for a user of the JAWS screen reader.
    I spent some time reading the SDK documentation but didn't find much information about manipulating a tagged PDF via the API, especially via scripting.
    Does anyone have any examples or references which explain how to do it?

    AFAIK, it's not possible with a script. You might want to ask in the SDK forum, as it could be possible with a plugin.

  • Use of default XACML with custom role mapper and authorization provider

    Hi,
    Is it possible to use the default XACML provider for custom role mappers and authorization providers when role information will be provided via an external application ( not an LDAP or RDBMS server )?
    My custom providers will be communicating with the external application via an API that accepts user credentials and will return decisions whether the credentials were successfully authenticated as well as returning a list of roles for the authenticated user.
    Once the roles and the subject are cached, will the default XACML provider be able to use them to make role mapping and authorization decisions?

    I see 2 approaches. First, write a custom authenticator that stores the role information in the subject either by creating a custom java.security.Principal that is stored in the Subject or by saving it in PrivateCredentials of the Subject. Then right a custom role mapper that knows how to get the role information from the Subject and return a role Map. The default XACML Authorizer will then work with the role information in the role map.
    Second approach is to write a custom role mapper that looks up the role information based on the Subject and returns a role map.
    The chosen approach depends on where you're getting the role information from.

  • BC4J Custom Type Maps   (MS-SQL cont.)

    (FYI using JDeveloper 9.0.2.0.0, MS-SQL 2000 spk2 and MS-SQL's JDBC driver Version 2.2.0022)
    In the process of trying to get JDeveloper working fully with MS-SQL, I am at the point of developing a custom type map.
    Should this typemap include all mappings or only those different than the "Java" or "Oracle" type map? I was assuming all at first. Now I wonder how it's handling missing mappings.
    How does it find a matching typemap? I noticed that Entity's database column types looked like "int(10,0)" and "bit(1,0)", but in my typemap, like the examples, it's just "INT", "BIT" with no precision, scale. Is this a case of where it's assuming the driver will return a string for type and it's returning type(p,s)? Or is JDev building that string? Either way, would you need a different mapping for "bit(1,0)" than "bit"?
    As "bit(1,0)" it had problems with both the Java map and my custom map. Changing it to "bit" seem to get it to work. So what typemapping was it trying to use as "bit(1,0)"?
    [Bug?] I noticed that when I view the bc4j settings (project (rt-click) -> edit business components project), the value for type map is incorrect if I am using a custom type map. If I am using the Java type map it says "Java" in the greyed out select, but if I am using my custom map ("MS-SQL"), it says "Oracle". I checked the bc4j.xcfg for the one using my custom map and it does say the right class name for jbo.TypeMapEntries.
    On a related note, when testing the bc4j modules, we are instructed to use the edited local configuration, but how do view/edit the project default configuration?
    ====================================================================
    typemap in progress...
    ================================
    public class MsSqlTypeMapEntries
    public MsSqlTypeMapEntries()
    /* ColumnType, JavaClassName, JdbcSqlType, JdbcSqlTypeID, DefaultDisplayLength, isNumericType */
    new JboTypeMap("BIGINT", "java.math.BigInteger", "BIGINT",java.sql.Types.BIGINT,null,true);
    //new JboTypeMap("BIGINT IDENTITY", "java.math.BigInteger", "BIGINT",java.sql.Types.BIGINT,null,true);
    //new JboTypeMap("BINARY BINARY
    new JboTypeMap("BIT","java.lang.Boolean","BIT",java.sql.Types.BIT,null,true);
    new JboTypeMap("CHAR","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    new JboTypeMap("DATETIME" ,"java.sql.Timestamp","TIMESTAMP",java.sql.Types.TIMESTAMP ,null);
    new JboTypeMap("DECIMAL","java.math.BigDecimal","DECIMAL",java.sql.Types.DECIMAL,null,true);
    //new JboTypeMap("DECIMAL() IDENTITY DECIMAL
    //new JboTypeMap("FLOAT FLOAT
    //new JboTypeMap("IMAGE LONGVARBINARY
    new JboTypeMap("INT","java.lang.Integer","INTEGER",java.sql.Types.INTEGER,null,true);
    new JboTypeMap("INT IDENTITY","java.lang.Integer","INTEGER",java.sql.Types.INTEGER,null,true);
    new JboTypeMap("MONEY","java.math.BigDecimal","DECIMAL",java.sql.Types.DECIMAL,null,true);
    new JboTypeMap("NCHAR","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    new JboTypeMap("NTEXT","java.lang.String","LONGVARCHAR", java.sql.Types.LONGVARCHAR, null);
    new JboTypeMap("NUMERIC","java.math.BigDecimal","NUMERIC",java.sql.Types.NUMERIC,null,true);
    //new JboTypeMap("NUMERIC() IDENTITY","java.math.BigDecimal","NUMERIC",java.sql.Types.NUMERIC,null,true);
    new JboTypeMap("NVARCHAR","java.lang.String","VARCHAR",java.sql.Types.VARCHAR,null);
    //new JboTypeMap("REAL REAL
    new JboTypeMap("SMALLDATETIME" ,"java.sql.Date","TIMESTAMP",java.sql.Types.TIMESTAMP ,null);
    new JboTypeMap("SMALLINT","java.lang.Integer","SMALLINT",java.sql.Types.SMALLINT,null,true);
    new JboTypeMap("SMALLINT IDENTITY","java.lang.Integer","SMALLINT",java.sql.Types.SMALLINT,null,true);
    new JboTypeMap("SMALLMONEY","java.math.BigDecimal","DECIMAL",java.sql.Types.DECIMAL,null,true);
    new JboTypeMap("SQL_VARIANT","java.lang.String","VARCHAR",java.sql.Types.VARCHAR,null);
    new JboTypeMap("SYSNAME","java.lang.String","VARCHAR",java.sql.Types.VARCHAR,null);
    new JboTypeMap("TEXT","java.lang.String","LONGVARCHAR", java.sql.Types.LONGVARCHAR, null);
    //new JboTypeMap("TIMESTAMP BINARY
    new JboTypeMap("TINYINT","java.lang.Integer","TINYINT",java.sql.Types.TINYINT,null,true);
    new JboTypeMap("TINYINT IDENTITY","java.lang.Integer","TINYINT",java.sql.Types.TINYINT,null,true);
    new JboTypeMap("UNIQUEIDENTIFIER","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    //new JboTypeMap("VARBINARY VARBINARY
    new JboTypeMap("VARCHAR","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    }

    (FYI using JDeveloper 9.0.2.0.0, MS-SQL 2000 spk2 and MS-SQL's JDBC driver Version 2.2.0022)
    In the process of trying to get JDeveloper working fully with MS-SQL, I am at the point of developing a custom type map.
    Should this typemap include all mappings or only those different than the "Java" or "Oracle" type map? I was assuming all at first. Now I wonder how it's handling missing mappings.
    How does it find a matching typemap? I noticed that Entity's database column types looked like "int(10,0)" and "bit(1,0)", but in my typemap, like the examples, it's just "INT", "BIT" with no precision, scale. Is this a case of where it's assuming the driver will return a string for type and it's returning type(p,s)? Or is JDev building that string? Either way, would you need a different mapping for "bit(1,0)" than "bit"?
    As "bit(1,0)" it had problems with both the Java map and my custom map. Changing it to "bit" seem to get it to work. So what typemapping was it trying to use as "bit(1,0)"?
    [Bug?] I noticed that when I view the bc4j settings (project (rt-click) -> edit business components project), the value for type map is incorrect if I am using a custom type map. If I am using the Java type map it says "Java" in the greyed out select, but if I am using my custom map ("MS-SQL"), it says "Oracle". I checked the bc4j.xcfg for the one using my custom map and it does say the right class name for jbo.TypeMapEntries.
    On a related note, when testing the bc4j modules, we are instructed to use the edited local configuration, but how do view/edit the project default configuration?
    ====================================================================
    typemap in progress...
    ================================
    public class MsSqlTypeMapEntries
    public MsSqlTypeMapEntries()
    /* ColumnType, JavaClassName, JdbcSqlType, JdbcSqlTypeID, DefaultDisplayLength, isNumericType */
    new JboTypeMap("BIGINT", "java.math.BigInteger", "BIGINT",java.sql.Types.BIGINT,null,true);
    //new JboTypeMap("BIGINT IDENTITY", "java.math.BigInteger", "BIGINT",java.sql.Types.BIGINT,null,true);
    //new JboTypeMap("BINARY BINARY
    new JboTypeMap("BIT","java.lang.Boolean","BIT",java.sql.Types.BIT,null,true);
    new JboTypeMap("CHAR","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    new JboTypeMap("DATETIME" ,"java.sql.Timestamp","TIMESTAMP",java.sql.Types.TIMESTAMP ,null);
    new JboTypeMap("DECIMAL","java.math.BigDecimal","DECIMAL",java.sql.Types.DECIMAL,null,true);
    //new JboTypeMap("DECIMAL() IDENTITY DECIMAL
    //new JboTypeMap("FLOAT FLOAT
    //new JboTypeMap("IMAGE LONGVARBINARY
    new JboTypeMap("INT","java.lang.Integer","INTEGER",java.sql.Types.INTEGER,null,true);
    new JboTypeMap("INT IDENTITY","java.lang.Integer","INTEGER",java.sql.Types.INTEGER,null,true);
    new JboTypeMap("MONEY","java.math.BigDecimal","DECIMAL",java.sql.Types.DECIMAL,null,true);
    new JboTypeMap("NCHAR","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    new JboTypeMap("NTEXT","java.lang.String","LONGVARCHAR", java.sql.Types.LONGVARCHAR, null);
    new JboTypeMap("NUMERIC","java.math.BigDecimal","NUMERIC",java.sql.Types.NUMERIC,null,true);
    //new JboTypeMap("NUMERIC() IDENTITY","java.math.BigDecimal","NUMERIC",java.sql.Types.NUMERIC,null,true);
    new JboTypeMap("NVARCHAR","java.lang.String","VARCHAR",java.sql.Types.VARCHAR,null);
    //new JboTypeMap("REAL REAL
    new JboTypeMap("SMALLDATETIME" ,"java.sql.Date","TIMESTAMP",java.sql.Types.TIMESTAMP ,null);
    new JboTypeMap("SMALLINT","java.lang.Integer","SMALLINT",java.sql.Types.SMALLINT,null,true);
    new JboTypeMap("SMALLINT IDENTITY","java.lang.Integer","SMALLINT",java.sql.Types.SMALLINT,null,true);
    new JboTypeMap("SMALLMONEY","java.math.BigDecimal","DECIMAL",java.sql.Types.DECIMAL,null,true);
    new JboTypeMap("SQL_VARIANT","java.lang.String","VARCHAR",java.sql.Types.VARCHAR,null);
    new JboTypeMap("SYSNAME","java.lang.String","VARCHAR",java.sql.Types.VARCHAR,null);
    new JboTypeMap("TEXT","java.lang.String","LONGVARCHAR", java.sql.Types.LONGVARCHAR, null);
    //new JboTypeMap("TIMESTAMP BINARY
    new JboTypeMap("TINYINT","java.lang.Integer","TINYINT",java.sql.Types.TINYINT,null,true);
    new JboTypeMap("TINYINT IDENTITY","java.lang.Integer","TINYINT",java.sql.Types.TINYINT,null,true);
    new JboTypeMap("UNIQUEIDENTIFIER","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    //new JboTypeMap("VARBINARY VARBINARY
    new JboTypeMap("VARCHAR","java.lang.String","CHAR",java.sql.Types.CHAR,null);
    }

  • Step-by-step custom Credential Mapping using weblogic 10.3 SSPI

    Folks,
    I am trying to implement custom Credential Mapping using weblogic 10.3 SSPI. Am sure that few of you have already implemented the same. But here my questions in reagrds with the implementation
    Right now, I have below
    1.MyCredentialMapperImpl implements CredentialMapperV2
    1.Overridden getCredential and gerCredentials method.But I am not sure what are all the other methods , I should implement here.
    2.MyCredentialMapperProviderImpl implements CredentialProviderV2
    Questions.
    1.How to get ContextHandler to pass as param in MyCredentialMapperImpl -->gerCredentials method.
    2.Should I need set up a database after deploying the MBean ?
    3.How do I execute above implementation ?
    4.Can I see the SAML Token in my client ?
    If possible Please send me the step-by-step custom Credential Mapping implementation.
    Thanks in advance.
    Ravi

    Hi John,
    I would like magic of course. However, in this case I want something special: my authentication provider uses special means and contents of headers, cookies and service from external identity management systems to determine the user's identity.
    I do not want the application to present the login dialog! I want to derive the identity and the fact that the user is logged in from whatever the authentication provider returns in terms of Subject.
    Ideally, the flow is something like:
    - user accesses an unprotected resource - resource is shown, no interaction with authentication provider
    - user presses a link or button that takes him/her to a protected resource
    - the authentication provider is contacted to work with the identity asserter to establish the identity of the current user and create a subject object for this user
    - the application can access the subject and principals
    - ADF Security recognizes the identity and the roles (based on the principals) and coordinates access based on this.
    the authentication method is client certificate. presumably this prompts WebLogic/OPS to use an identity asserter to work with custom headers and cookies ("... when you configure a web application to use CLIENT-CERT authentication. In this case, WebLogic can perform identity assertion based on values from request headers and cookies. If the header name or cookie name matches the active token type for the provider, the value is passed to the provider."). No login form should be presented to the user, as all information required to perform the authentication is already available.
    I am trying to understand what I must do to have the ADF application adopt the subject set by the authentication provider - if anything?!
    If you more ideas to share - I would love to hear them.
    best regards,
    Lucas

  • Converting custom Google map to PDF

    Is it possible to take a customized Google map (showing points of interest we've created) and turn it into a pdf that would be zoomable, and in which each of those points would be clickable (or via mouseover) to show information about those points? If the answer is yes, is their functionality that would allow this to be viewed on a mobile device?  Thanks! If there isn't an Adobe solution that would accomplish this, do you know of some other solution?  Here's an example of the type of map I want to be able to convert to PDF and have each icon identifiable in some manner:

    I have a feeling Google would make this as difficult as they can.
    If I'd been asked to do this, I'd be worrying very much about Google's licensing of map data and whether making an "offline copy" was breaking the license. http://www.google.com/permissions/geoguidelines.html. How is your copyright law?
    Google do offer a maps API which can be used to deliver maps on mobile devices. That might be the safer option.

  • E-Commerce for ERP role mapping to UME

    Experts,
    We have successfully configured the ECO module to use the UME in addition to SU01.  We are able to create users in both systems in ISAUSERADMIN.  However, the newly created users in UME have no roles assigned to them.  We found one SAP Note that seems to be relevant ([891151|https://service.sap.com/sap/support/notes/891151]).  Unfortunately, it is very vague on how to setup the user mapping.  We have tried several permutations of the role assignments to no avail.
    Has anyone done this before, and if so could you provide some examples?

    We discovered the problem.  We were updated the right file for the wrong application.  The file ume-config.xml needs to updated from the application crm~isauseradm.  Once we discovered this, the UME role mapping worked.  We are now able to assign UME roles to a new user when they are created or updated in ISAUSERADMIN.
    - Andrew

  • Protected URL vs role mapping in OAM

    Hi,
    Can we do map Protected URL vs role mapping ?
    for example I have some ULR need to be protected thru OAM. Now based on url, user should get the screen. I have user and role in OID.
    My Doubt is : Once user it authenticated, how IDM is conforming that user has access to particular URL or not ?
    or is there any way to do so ? Can I map my 50 URL to 50 role and assign this role to user in oracle IDM?
    Any Help Apprecaited.

    I am too looking for something similar i.e. if users requested url is '/xyz' check if they are in role 'admin' or 'abcde' if not then authentication fails.
    If you find anything please share.
    Thanks

  • OIM 11g add custom role on user creation

    Hi,
    I when i create a user in OIM11g by default it gets added to "ALL USERS" role.
    I have created a new role and want to add user to this custom role while creating users. How can i do this in OIM11g
    Regards,
    Ab
    Edited by: 824473 on Jan 18, 2011 2:33 AM

    set Auto submit true. you can't set the value for ValueChangedListener property in current release of R2. This is bug and you can raise SR for same. But, this won't cause saving data into USR table. ValueChandedListener property for Modify User page only.
    As you said, data is not being saved in the USR table then verify your steps again:
    create sandbox->users->create user/edit user/view user details page->click customize->leftTopcorner->View->Source->select area->edit->Click Add Content (on left top)->Data Component catalog->scroll down and select User VO->Refresh dialogue box->select the field and click 'Add'->on dropdown select 'ADF Input test w/label/for view user page it should be output test w/label->close that window->Check if it added to create user form->save and close customization
    for user detail page select "Managed User->UserVo1 " as datacomponent
    Re: UDF creation on User form in 11gR2
    for valuechangedlistener the fixes all ready available. you have to do some workaround as other poster has given in above link:
    1.Create a sandbox and activate it. Open the page that contains the UDF, and click Customize.
    2.Select View, Source.
    3.Note the value of the valueChangeListener property of a predefined field. To do so:
    a.Click the predefined field, and then click Edit to open the Component Properties dialog box.
    b.Copy the value of the valueChangeListener property.
    4.Export the sandbox as a ZIP file.
    5.Extract the ZIP file and edit the jsff.xml file for the specific screen.
    6.Add the following attributes to the ADF tag, for example af:inputText, for the UDF:
    ◦valueChangeListener=VALUE_COPIED_IN_STEP3
    ◦autoSubmit="true"
    7.Create the ZIP file for the sandbox.
    8.Import the sandbox.
    9.Publish the sandbox.
    Edited by: Nishith Nayan on Sep 21, 2012 1:04 PM

  • Problem with Security Role mapping and LDAP

    Hi,
    In Oracle Internet Directory I've created a group called OIDGroup1.OIdGroup1 has 2 users : OIDuser1 and OIDuser2.
    OIDGroup1 is mapped to EjbRole1 (is a security role defined in ejb-jar.xml, EjbRole1 can do everything in the application).Now if I login as OIDuser1 or OIDuser2, application said that the user does not
    have authorization to execute some method. The mapping in my orion-application.xml is :
    <security-role-mapping name="EjbRole1">
    <group name="admin/OIDGroup1"/>
    </security-role-mapping>
    <jazn provider="LDAP" location="ldap://myhost:4032"><jazn-web-app auth-method="SSO"/></jazn>
    if I modified orion-application.xml like this :
    <security-role-mapping name="EjbRole1">
    <group name="admin/OIDGroup1"/>
    <user name="admin/OIDuser1"/>
    </security-role-mapping>
    then login as OIDuser1, it works. But it does not work with OIDuser2.
    That's is a problem for me because our customer can not manage the user/group
    easily : each time they have a a new user, instead of simply adding this user
    in the OIDGroup1 (with graphic interface of OIDAS), they have to modify
    orion-application.xml.
    Do you have any idea ?
    Thanks in advance
    regards

    I found the bug : in LDAP I've got a user also called OIDGroup1 (the same as group's name).

  • User / Customer Role Membership Check in ISF / Javascript

    Did not see this in the documentation...
    Does anyone know if checking for the User or Customer Role membership inside ISF / Javascript is supported? -- Like similar to how we can check for "Moment".
    If so, what is the variable name and the values?
    Thanks.

    I think some of the libraries such as ExtJS are loaded and usable on the order forms, but for ones that are not, you can point to the existing library files under RequestCenter.war and add them as a JavaScript library in service designer.
    Below is a quick example of looking up the role through the NS API, it should be enough to get you started on what you need.
    function doSomething(){
        //Performs NS API XHR Request and returns the responseXML document
        function nsapiRequest(url) {
            var xhr = new XMLHttpRequest();
            xhr.open("GET", url, false);
            xhr.send();
            if (xhr.readyState === 4) {
                if (xhr.status === 200) {
                    return xhr.responseXML;
                } else {
                    console.error(xhr.statusText);
        //Function to check if user belongs to a role
        function hasRole(roleName) {
            var doc = nsapiRequest("/RequestCenter/nsapi/directory/people/currentuser");
            //Get all associated role elements
            var roles = doc.getElementsByTagName("associatedRole");
            //Loop through roles to check for a specific one, could also build an array of all user roles
            for (var i = 0; i < roles.length; i++) {
                //Extract role value
                var role = roles[i].childNodes[1].firstChild.nodeValue;
                if (role === roleName)
                    return true;
            return false;
        var siteAdmin = hasRole("Site Administrator");
        if (siteAdmin){
            //do something

  • Error while assigning portal custom role

    Hi All,
    We have a custom role which we use to assign to the users.  till now we are able to assign it without any problem.  But now as i need to assign it to someone, i got an error stating that "An error occured while adding user assignments; to see the correct status, perform a new assigned user search".
    Can anybody help us in finding out the reason of the error and in rectifying the error.
    Thanks & Regards,
    Ravi

    Hi Raghu,
    Thanks for your reply..
    This role is existing in the PCD, and this error is coming, while assinging this role any users... it is working fine with the existing users, who are having this role before.  This is happening only when we are assigning this role to some new user. 
    I dont think this has some relation with the backend, as the role assignment is part of the Portal itself.
    And also here we dont have seperate UME, and we are using r3 users only with single sign on.....
    Hi Jithendar,
    Thanks fo your reply.....I will do that backend roles check also for those users and see whether any backend role variations happened for these users.
    Thanks & Regards,
    Ravi

Maybe you are looking for