+
    4Ssi8  ã                   óx   € ^ RI Ht ^ RIHt ^ RIHt ^ RIHt ^ RI	H
t
 ^ RIHtHtHt ^ RIHt  ! R R	]4      tR# )
é    N)Úldb)Úsystem_session)Úsecurity)Ú
ndr_unpack)ÚCommandÚCommandErrorÚOption)ÚSamDBc            	       ó¤   a € ] tR t^t o RtRtR]P                  R]P                  R]P                  /t
]! RRR]R	R
R7      .tRR.tRR ltRtV tR# )Úcmd_user_setprimarygroupaI  Set the primary group a user account.

This command sets the primary group a user account. The username specified on
the command is the sAMAccountName. The primarygroupname is the sAMAccountName
of the new primary group. The user must be a member of the group.

The command may be run from the root userid or another authorized userid. The
-H or --URL= option can be used to execute the command against a remote server.

Example1:
samba-tool user setprimarygroup TestUser1 newPrimaryGroup --URL=ldap://samba.samdom.example.com -Uadministrator%passw1rd

Example1 shows how to set the primary group for TestUser1 on a remote LDAP
server. The --URL parameter is used to specify the remote target server.  The
-U option is used to pass the username and password of a user that exists on
the remote server and is authorized to update the server.
z-%prog <username> <primarygroupname> [options]Ú	sambaoptsÚversionoptsÚcredoptsz-Hz--URLz%LDB URL for database or target serverÚURLÚH)ÚhelpÚtypeÚmetavarÚdestÚusernameÚprimarygroupnameNc           	     ó  € VP                  4       pVP                  V4      p\        V\        4       W‡R 7      p	R\        P
                  ! V4      ,          p
 V	P                  V	P                  4       V
\        P                  R.. ROR7      pV^ ,          P                  R^ R7      p\        \        P                  V4      pVP                  4       w  rïRV,          p\        V^ ,          P                  R^ R7      4      pV^ ,          P                  R4      pVf   . p. pT F_  p\        P"                  ! T	\%        T4      4      pTP'                  R4      p\        \        P                  T4      pTP)                  T4       Ka  	  R\        P
                  ! T4      ,          p
 T	P                  T	P                  4       T
\        P                  R.R7      pT^ ,          P                  R^ R7      p\        \        P                  T4      pTP                  4       w  ppTT8w  d   \!        RT,          4      hTT8w  d   TT9  d   \!        RT: RT: R24      hRTTT3,          p T	P+                  T4       T P.                  P1                  RT,          4       R	#   \         d    \!        R
T,          4      hi ; i  \         d    \!        RT,          4      hi ; i  \,         d   p\!        RT: RT: RT: 24      hR	p?ii ; i))ÚurlÚsession_infoÚcredentialsÚlpz((&(sAMAccountName=%s)(objectClass=user))zextended_dn:1:1Ú	objectSidÚmemberOfÚprimaryGroupID)ÚbaseÚ
expressionÚscopeÚcontrolsÚattrs)Úidxz<SID=%s>NzUnable to find user '%s'ÚSIDz)(&(sAMAccountName=%s)(objectClass=group)))r    r!   r"   r$   zUnable to find group '%s'z/Group '%s' does not belong to the user's domainzUser 'z' is not member of group 'Ú'zl
dn: %s
changetype: modify
delete: primaryGroupID
primaryGroupID: %u
add: primaryGroupID
primaryGroupID: %u
zFailed to set primary group 'z' for user 'z': zChanged primary group to '%s'
)r   r   r   )Úget_loadparmÚget_credentialsr
   r   r   Úbinary_encodeÚsearchÚ	domain_dnÚSCOPE_SUBTREEÚgetr   r   Údom_sidÚsplitÚintÚ
IndexErrorr   ÚDnÚstrÚget_extended_componentÚappendÚmodify_ldifÚ	ExceptionÚoutfÚwrite)Úselfr   r   r   r   r   r   r   ÚcredsÚsamdbÚfilterÚresÚuser_sid_binaryÚuser_sidÚuser_dom_sidÚuser_ridÚuser_sid_dnÚ	user_pgidÚuser_groupsÚuser_group_sidsÚ
user_groupÚuser_group_dnÚuser_group_binary_sidÚuser_group_sidÚgroup_sid_binaryÚprimarygroup_sidÚprimarygroup_dom_sidÚprimarygroup_ridÚsetprimarygroup_ldifÚmsgs   &&&&&&&                       ÚC/usr/lib/python3/dist-packages/samba/netcmd/user/setprimarygroup.pyÚrunÚcmd_user_setprimarygroup.run@   sû  € ð ×#Ñ#Ó%ˆØ×(Ñ(¨Ó,ˆä˜!¬.Ó*:Ø"'ô0ˆð =Ü×#Ò# HÓ-õ.ˆð	HØ—,‘, E§O¡OÓ$5Ø*0Ü%(×%6Ñ%6Ø):Ð(;ò&8ð	 ó 9ˆCð " !�fŸj™j¨¸!˜jÓ<ˆOÜ!¤(×"2Ñ"2°OÓDˆHØ'/§~¡~Ó'7Ñ$ˆ\Ø$ xÕ/ˆKÜ˜C �FŸJ™JÐ'7¸Q˜JÓ?Ó@ˆIØ˜a�&Ÿ*™* ZÓ0ˆKØÒ"Ø �ð ˆÛ%ˆJÜŸFšF 5¬#¨j«/Ó:ˆMØ$1×$HÑ$HÈÓ$OÐ!Ü'¬×(8Ñ(8Ð:OÓPˆNØ×"Ñ" >Ö2ñ	 &ð >Ü×#Ò#Ð$4Ó5õ6ˆð	QØ—,‘, E§O¡OÓ$5Ø*0Ü%(×%6Ñ%6Ø&1 ]ð ó 4ˆCð  # 1�vŸz™z¨+¸1˜zÓ=Ðô &¤h×&6Ñ&6Ð8HÓIÐØ3C×3IÑ3IÓ3KÑ0Ð	Ð/àÐ/Ô/Üð  (Ø*:õ ;ó <ð <ð ˜yÔ(Ð-=À_Ô-TÝÛ (Ó*:ð <ó =ð =ð ð �IÐ/Ð0õ 1Ðð	BØ×ÑÐ2Ô3ð
 	�	‰	�‰Ð9Ð<LÕLÖMøô_ ô 	HÜÐ9¸XÕFÓGÐGð	Hûô$ ô 	QÜÐ:Ð>NÕOÓPÐPð	Qûô2 ô 	BÝã 0³(ºCð Aó Bð Bûð	Bús2   ÁCJ Æ AJ7 É!K ÊJ4Ê7KËK?Ë#K:Ë:K?© )NNNN)Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__ÚsynopsisÚoptionsÚSambaOptionsÚVersionOptionsÚCredentialsOptionsÚtakes_optiongroupsr	   r4   Útakes_optionsÚ
takes_argsrS   Ú__static_attributes__Ú__classdictcell__)Ú__classdict__s   @rR   r   r      sw   ø‡ € ñð" ?€Hð 	�W×)Ñ)Ø�w×-Ñ-Ø�G×.Ñ.ðÐñ 	ˆt�WÐ#JÐQTØ 3ô	(ð
€Mð
 Ð0Ð1€J÷JNò JNó    r   )Úsamba.getoptÚgetoptr\   Úsambar   Ú
samba.authr   Úsamba.dcerpcr   Ú	samba.ndrr   Úsamba.netcmdr   r   r	   Úsamba.samdbr
   r   rU   rf   rR   Ú<module>ro      s/   ðõ, Ý Ý %Ý !Ý  ß 6Ñ 6Ý ôkN˜wö kNrf   