----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/53441/#review154866 -----------------------------------------------------------
I did a quick review and it is looking good. I will let someone familiar with the code to sign off - Don Bosco Durai On Nov. 4, 2016, 4:42 a.m., Shi Wang wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/53441/ > ----------------------------------------------------------- > > (Updated Nov. 4, 2016, 4:42 a.m.) > > > Review request for ranger, Don Bosco Durai and Madhan Neethiraj. > > > Repository: ranger > > > Description > ------- > > The solution is not specific to admin user. > We can use security-admin/scripts/changeusernameutil.py to change any user's > username, as long as we know the old user name and password. > The usage is changeusernameutil.py <loginuserid> <password> <newusername> > If the old username(loginuserid) cannot be found in database or password not > correct, or new username is the same with old username it will not proceed to > change username. > > > Diffs > ----- > > security-admin/scripts/changeusernameutil.py PRE-CREATION > security-admin/src/main/java/org/apache/ranger/biz/UserMgr.java 9885090 > > security-admin/src/main/java/org/apache/ranger/patch/cliutil/ChangeUserNameUtil.java > PRE-CREATION > src/main/assembly/admin-web.xml b06cdec > > Diff: https://reviews.apache.org/r/53441/diff/ > > > Testing > ------- > > 1. changeusernameutil.py admin admin wangshi --> user name update > successfully. > 2. changeusernameutil.py admin admin wangshi (after 1) --> username not found. > 3. changeusernameutil.py wangshi admin wangshi --> newusername same with > loginuserid > 4. changeusernameutil.py wangshi wangshi admin --> password invalid. > > > Thanks, > > Shi Wang > >
