I have a website which using active directory authorization on a windows server
in order to use active directory, the os must join to active directory domain
now, since some security issue, the admin of server don’t want to join to domain persistently
are there any ways to join to domain programmatically, when the website need to authorize a user, then connect to domain, after authorization, disconnect from domain?
If you really want to join to the domain programmatically, you can look at this SO post.
Another option is to provide username and password when binding to Active Directory but that means you need to find a way to store the username and password securely. You can store them securely using DPAPI