Project

General

Profile

Bug #32382

Ensure group.query middleware call provides information about primary users belonging to a group

Added by Vaibhav Chauhan 12 months ago. Updated 10 months ago.

Status:
Done
Priority:
No priority
Assignee:
Brandon Schneider
Category:
Middleware
Target version:
Severity:
Low Medium
Reason for Closing:
Reason for Blocked:
Needs QA:
No
Needs Doc:
No
Needs Merging:
No
Needs Automation:
No
Support Suite Ticket:
n/a
Hardware Configuration:
ChangeLog Required:
No

Description

currently

root@freenas-vb:~ # midclt call group.query '[["id","=",40]]'
[{"id": 40, "gid": 1000, "group": "test_usr", "builtin": false, "sudo": false, "users": []}]

provides no information about primary users that belong to this group.

root@freenas-vb:~ # midclt call user.query '[["uid","=",1000]]'
[{"id": 55, "uid": 1000, "username": "test_usr", "unixhash": "$6$D9tASjUfNUrI14vi$CfYtkVEg8IDtbCa6MZ50kmal9Yd8hkaFLP.r9H8MKrH2MSk0zFri64dPUJsFWkuklVH5xMVUdrUbUEab7G4xo/", "smbhash": "test_usr:1000:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:FE59D18A2131399C5E16D60ECD9A9A25:[U          ]:LCT-5AD6E40C:", "group": {"id": 40, "bsdgrp_gid": 1000, "bsdgrp_group": "test_usr", "bsdgrp_builtin": false, "bsdgrp_sudo": false}, "home": "/nonexistent", "shell": "/bin/csh", "full_name": "test_usr", "builtin": false, "email": "", "password_disabled": false, "locked": false, "sudo": false, "microsoft_account": false, "attributes": {}, "groups": [], "sshpubkey": null}]

root@freenas-vb:~ # midclt call user.query '[["uid","=",1001]]'
[{"id": 56, "uid": 1001, "username": "test_usr1", "unixhash": "$6$sLPKO9pqJHA7vkXz$d5UIpwl5e.E2ixOw7GZfn1xzXCpEugU3F2sj7H3UouWstuOEQ9RyozzKRiyqcEMexTOprC5SQEw8CJwXZTlos0", "smbhash": "test_usr1:1001:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:FE59D18A2131399C5E16D60ECD9A9A25:[U          ]:LCT-5AD6E43F:", "group": {"id": 40, "bsdgrp_gid": 1000, "bsdgrp_group": "test_usr", "bsdgrp_builtin": false, "bsdgrp_sudo": false}, "home": "/nonexistent", "shell": "/bin/csh", "full_name": "test_usr", "builtin": false, "email": "", "password_disabled": false, "locked": false, "sudo": false, "microsoft_account": false, "attributes": {}, "groups": [], "sshpubkey": null}]

root@freenas-vb:~ # midclt call user.query '[["uid","=",1002]]'
[{"id": 57, "uid": 1002, "username": "test_usr2", "unixhash": "$6$9Ua2mI5HOSaHUXE5$LbzkpCSuUGDgXpa9uuCii5oFqXH8BKJxhrBWbUlHH89PJnzRImQ7fpMmC0T/cyBXb4soH6VNbl7iWO2al6Bh5.", "smbhash": "test_usr2:1002:XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX:FE59D18A2131399C5E16D60ECD9A9A25:[U          ]:LCT-5AD6E45F:", "group": {"id": 40, "bsdgrp_gid": 1000, "bsdgrp_group": "test_usr", "bsdgrp_builtin": false, "bsdgrp_sudo": false}, "home": "/nonexistent", "shell": "/bin/csh", "full_name": "test_usr2", "builtin": false, "email": "", "password_disabled": false, "locked": false, "sudo": false, "microsoft_account": false, "attributes": {}, "groups": [], "sshpubkey": null}]

Related issues

Blocks FreeNAS - Bug #30897: (New UI) Account/Users/Delete missing option.Done2018-03-28

Associated revisions

Revision a5897ad4 (diff)
Added by Brandon Schneider 12 months ago

(fix/account): Add non-builtin user/groups to the user list for query

Ticket: #32382

Revision 08f891fe (diff)
Added by Brandon Schneider 12 months ago

(fix/account): Add user/groups to the user list for query (#1127)

Ticket: #32382

History

#1 Updated by William Grzybowski 12 months ago

  • Assignee changed from William Grzybowski to Brandon Schneider
  • Target version set to 11.2-BETA1
  • Severity set to Low Medium

Brandon, this seems very straightforward, can you take care of it, please?

#2 Updated by Vaibhav Chauhan 12 months ago

  • Blocks Bug #30897: (New UI) Account/Users/Delete missing option. added

#3 Updated by Vaibhav Chauhan 12 months ago

  • Subject changed from group.query may needs to provide information about primary users that are belong to this groups to group.query may needs to provide information about primary users that are belonging to this group

#4 Updated by Brandon Schneider 12 months ago

  • Status changed from Unscreened to Not Started

#5 Updated by Brandon Schneider 12 months ago

  • Status changed from Not Started to In Progress

#6 Updated by Brandon Schneider 12 months ago

  • Status changed from In Progress to Ready for Testing

#7 Updated by Dru Lavigne 12 months ago

  • Subject changed from group.query may needs to provide information about primary users that are belonging to this group to Ensure group.query middleware call provides information about primary users belonging to a group
  • Needs Doc changed from Yes to No
  • Needs Merging changed from Yes to No

#8 Avatar?id=55038&size=24x24 Updated by Zackary Welch 10 months ago

  • Needs QA changed from Yes to No

Is this with regards to the group.query returning a "users" array? If so this seems to work, since I created a group with a couple of users in it and the ids from the group query match the users in the group.

#9 Avatar?id=55038&size=24x24 Updated by Zackary Welch 10 months ago

  • Status changed from Ready for Testing to Passed Testing

#10 Updated by Dru Lavigne 10 months ago

  • Status changed from Passed Testing to Done

Also available in: Atom PDF