I have redmine hooked into Active Directory LDAP. I've seen a plugin for mapping LDAP users to a default group, but not sure if there's a plugin out there for mapping users to specific projects.
UserA belongs to "Dev A redmine" group in AD, when he logs into Redmine he automatically gets added to the Dev A project and subprojects.
You could use API to do that.
You can make somethings to read l dap and make membership (it is what I do).