Clarity

Expand all | Collapse all

Remove resources from a security group using XOG

System

SystemMar 14, 2013 10:42 AM

Deactivated User

Deactivated UserMar 15, 2013 07:46 AM

navzjoshi00

navzjoshi00Mar 15, 2013 09:10 AM

  • 1.  Remove resources from a security group using XOG

    Posted Mar 14, 2013 08:49 AM
    Hi,
    Is there a way we can remove all users from a security group using XOG? I understand, since this is for all, removing them manually will not take much time but just want to know if there is an option for this using XOG.


  • 2.  Moving to Clarity XOG/GEL/WSDL Board

     
    Posted Mar 14, 2013 10:42 AM
    Moving to Clarity XOG/GEL/WSDL Board


  • 3.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 02:01 AM
    What about xogging out the security group, clearing the members tag, and xogging back in ? - Haven't tried though

    NJ


  • 4.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 02:08 AM
    Sorry, checked now... did not work... would be worth finding the solution !!! ... :tongue:

    NJ


  • 5.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 04:21 AM
    Removing resources/users/projects or any other object from the XOG file will not help in removing those objects.


  • 6.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 06:26 AM
    Does the complete="true" arg to the XOG help.


  • 7.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 07:16 AM
    Hi Dave,
    Below is what we get for users added to the groups while xoggin out.
    <members>
    <resource userName="user1"/>
    </members>

    I tried adding <members completed="true"> but the XML got invalid.
    Please let me know if there is an option in Security Groups XML to add completed="true". I guess this will only be there for users OUT XML.


  • 8.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 07:29 AM
    I don't think there is.
    Members appears to be again one of those thinks you can ad, but not remove or modify with XOG.

    On the other hand why bother.

    Just read the group, edit the xml file and remove all the resources. DELETE THE GROUP IN THE GUI and write back.

    That should be simple because all the resources are in one place.no matter how many rights there are and how complicated they are.

    Martti K.

    EDIT OOPS missed the key step from the list. :*)


  • 9.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 07:46 AM
    EDIT OOPS missed the key step from the list. :*)


  • 10.  RE: Remove resources from a security group using XOG
    Best Answer

    Posted Mar 15, 2013 08:48 AM
    <?xml version="1.0" encoding="UTF-8"?>
    <NikuDataBus xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../xsd/nikuxog_group.xsd">
      <Header action="write" externalSource="NIKU" objectType="group" version="13.0.0.7032"/>
      <groups>
        <group code="testgroup" isActive="true">
          <nls description="testgroup" languageCode="en" name="testgroup"/>
          <members [color=#ff0000]complete="true"[/color]>
            <resource userName="david"/>
          </members>
          <rights>
            <InstanceRights/>
            <InstanceOBSRights/>
          </rights>
        </group>
      </groups>
    </NikuDataBus>
    Worked OK for me to just remove two other resources from my testgroup. (v13.0 xog using the GUI client)

    --

    jerins wrote:

    I tried adding <members completed="true"> but the XML got invalid.
    Syntax ; complete not complete[color=#ff0000]d[color]


  • 11.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 09:10 AM
    Thanks Dave :happy:

    NJ


  • 12.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 09:14 AM
    Works also in v12.1

    It is complete for group members and OBS and completed when assigning rights to gorups or resources.

    Martti K.


  • 13.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 09:20 AM

    another_martink wrote:

    It is complete for group members and OBS and completed when assigning rights to gorups or resources.
    Aaaaaah the consistency, the consistency! :grin:

    (well at least I posted the right one in my original (brief) response! :ph34r: )


  • 14.  RE: Remove resources from a security group using XOG

    Posted Mar 15, 2013 10:20 AM
    Yeah, I tried it with the "d" and got the error, so I thought of the other way.

    Martti K.


  • 15.  RE: Remove resources from a security group using XOG

    Posted Mar 16, 2013 01:38 AM
    I tried it the below way but still it did not work :(.. Did not give me any fatal message but the resource is still there in the group. :(

    <members complete="true">
    <resource userName="jerins"/>
    </members>


  • 16.  RE: Remove resources from a security group using XOG

    Posted Mar 16, 2013 03:33 AM
    Sounds as if it worked just as it is supposed:

    It writes the group with just one member - jerins


    If you don't want any members in the group try

    <members complete="true">
    </members>


    Martti K.


  • 17.  RE: Remove resources from a security group using XOG

    Posted Mar 16, 2013 06:08 AM
    Well, thre is only one user in that group. I tired adding one more resource to the group, xogged out and tried xogging in again using complete=true but still dint work :( ! !

    is this something working for you guys and not for me alone??? If so I will try in a different environment and validate this.


  • 18.  RE: Remove resources from a security group using XOG

    Posted Mar 16, 2013 06:21 AM

    jerins wrote:

    .....xogged out and tried xogging in again using complete=true....
    XOG it out. Edit the XML to remove the members that you do not want in the group from the <members> section, add the complete="true" and then XOG it in.


  • 19.  RE: Remove resources from a security group using XOG

    Posted Mar 16, 2013 06:45 AM
    It certainly works - for me.
    What kind of XOG rights do you have? Like
    User - XOG Access
    Allows user to import and export User instances using the XML Open Gateway interface?

    Martti K.


    .


  • 20.  RE: Remove resources from a security group using XOG

    Posted Mar 18, 2013 04:43 AM
    It worked ! ! ! !
    I actually did not empty out the users under the member tag and was expecting the complete = "true" to nullify the whole set of resources. My bad but I am happy its working now and things are much easier for me.

    Thanks Dave.

    - Jerin


  • 21.  RE: Remove resources from a security group using XOG

    Posted Apr 21, 2014 11:53 AM

    Hi All,

    How we can achive this using Process(GEL Script)?

    Any thoughts

    Thanks

    Hari



  • 22.  RE: Remove resources from a security group using XOG

    Posted Apr 23, 2014 11:49 AM

    You just use GEL to call the XOG (constructing an XML message, calls XOG over SOAP etc).

    (There is a lot of information on calling XOG from GEL on these boards - see the Gel.zip file attached to the FAQ THREAD for a start.)
     



  • 23.  Re: RE: Remove resources from a security group using XOG

    Posted Feb 27, 2015 06:37 AM

    Hello David,

     

    Can you please tell me the way to remove a specific instance right from the user and it is performed with the help of process/GEL script?

     

    We want to automate the process of removing a specific right from the user.  Do not want to manually edit the XOG file of the user and remove that specific right and make other set of rights as complete='true'.

     

    Thank you in advance

     

    Pragya Singh



  • 24.  Re: Remove resources from a security group using XOG

    Posted Feb 27, 2015 07:01 AM

    sparc.helpdesk wrote:

     

    Hello David,

     

    Can you please tell me the way to remove a specific instance right from the user and it is performed with the help of process/GEL script?

     

    We want to automate the process of removing a specific right from the user.  Do not want to manually edit the XOG file of the user and remove that specific right and make other set of rights as complete='true'.

     

    Thank you in advance

     

    Pragya Singh

    You would use the same sort of process as described in this thread for group membership, just for instance rights.

     

    i.e. XOG read out the user, amend the XML to remove the right(s) you are interested in and also to add in the "complete" flag, XOG the XML back into the application - all controlled via a GEL script (no "manual" edits anywhere).

     

    (Of course this is a somewhat fiddly GEL script / XML manipulation to build ; much easier to just go into the GUI and remove the access right manually, its only worth building an automated-script if you really really really need to be doing this many times).



  • 25.  Re: Remove resources from a security group using XOG

    Posted Feb 27, 2015 07:11 AM

    Hello David,

     

    Thank you for the suggestion.

     

    The effort of creating automated process to add/remove rights are much higher than manually doing it, if this activity is performed very rarely for the users.

     

    Better to do it manually.

     

    We will check the demand of this automated process then plan for creating it. Otherwise, will perform manually.

     

    Thanks,

    Pragya Singh



  • 26.  Re: Remove resources from a security group using XOG

    Posted Jul 07, 2016 03:28 AM

    Hello Everyone,
    Suppose if there are 20 members in a group then if we put  complete="true" and hardcode a user name (ex:admin) then  admin will be the only member of that group rest all other members are removed.

     

                      <groups>

                        <group code="temp_group" isActive="true">

                          <nls languageCode="en" name="temp group"/>

                          <members  complete="true" >

                                    <resource userName="${admin}"/>

                          </members>

                        </group>

                      </groups>

            

    Is there any other alternate that If we set Complete="false" or some other attr="somevalue" then the user who is in userName should get removed.????.

     

    Santosh.