Yes. Multiple ways.
You can write a custom script and deploy with the Run Scripts feature. (Or you can easily find a PowerShell script on the web for this as well.)
You can use CMPivot which contains an entity for exactly this.
You can extend hardware inventory to do this. Once again, searching the web will give you info on folks who have done this before and how they've done it (including this one: https://tcsmug.org/blogs/sherry-kissinger/244-all-members-of-all-local-groups-configmgr-2012).