Hello Roberto,
I also wanted the users to have the same credentials to use both on my django project and the EDMS. However, I was unable to find a way to do that. I tried using the same database for both projects, so that auth tables would be the same, but I didn't like the final result (lots of tables that I'm not sure what project are from, living in the same space).
I was looking around on using Multiple databases for django. (
https://docs.djangoproject.com/en/dev/topics/db/multi-db/). I tried to define a couple of db routers for mayan-edms, so that authentication happened on database1 (my project's database) and the rest of tables were written on database2. I didn't have luck with that, plus the very same documentation says that "cross-database retionships
introduce referential integrity problems that Django can’t
currently handle".
So, I ended up choosing to abandon this project and now I'm setting a webdav shared directory for document sharing :(.