Skip to content

cake-contrib/Cake.ActiveDirectory

 
 

Repository files navigation

Cake.ActiveDirectory

Cake Addin for working with Active Directory.

Give a Star! ⭐

If you like or are using this project please give it a star. Thanks!

Information

Stable Pre-release
GitHub Release - GitHub release
NuGet NuGet
NuGet

Quick Links

Build

To build this package we are using Cake.

On Windows PowerShell run:

./build

About

This Addin only contains the functionality that we needed. We are more than happy to accept pull requests that will grow this library. It uses the LandPy.ActiveDirectory library for all Active Directory interaction.

Usage

Adding to your cake file

//Beta version
#addin nuget:https://www.myget.org/F/beta-builds/api/v2?package=Cake.ActiveDirectory 

// Release version
#addin nuget:?package=Cake.ActiveDirectory 

Creating a user

CreateUser("cake-user", "cake-group", new UserSettings { 
    LoginName = "domainAdmin", 
    Password = "adminPassword", 
    DomainName = "Cake.net"});

Updating a user

UpdateUser("employeeId", "1234", new UserSettings { 
    LoginName = "domainAdmin", 
    Password = "adminPassword", 
    DomainName = "Cake.net",
    Email = "test@cake-yeah.com" });

Getting a user's UPN from their email address.

var upn = FindUserPrincipalNameByProperty("proxyAddresses", "jdoe@example.com", new UserSettings { 
            LoginName = "domainAdmin", 
            Password = "adminPassword", 
            DomainName = "Cake.net" });

Discussion

For questions and to discuss ideas & feature requests, use the GitHub discussions on the Cake GitHub repository, under the Extension Q&A category.

Join in the discussion on the Cake repository

Release History

Click on the Releases tab on GitHub.


Copyright © 2017-2021 Cake Contributors - Provided under the MIT License.