How can LDAP/Active Directory be integrated in WordPress?

Best thing is to learn as much as you can from the available plugins even if they are not a perfect match to your requirements. This will help you identify areas of functionality which you will need to handle.

As for coding itself, for the authentication part you will most likely need to override the authenticate filter which lets you do user/password authentication before wordpress tries by itself.

Authorization can be a complex beast and I am not sure what kind of it you will need so can’t even guess what will be useful. You most likely will need to get familiar with user roles and permissions.