Today, I will talk about configuring your PowerShell Web Access to work with Active Directory cmdlet.
First of all, I want to thank's tommymaynard who help me with that. You can see my question here from powershell.org.
Procedure
- I assumed you have PSWA installed and configured. Mine, is on Windows 2012 R2 STD Core dedicated for that.
- Install the AD PowerShell Tools on the server if it's not installed : Add-WindowsFeature RSAT-AD-PowerShell
- At this point, if you tried to run AD Cmdlet from PSWA this will failed.
- Create a configuration file store on your PSWA server : New-PSSessionConfigurationFile -Path C:\yourpath\filename.pssc
- You need to register the files and put the good credential to elevate the session : Register-PSSessionConfiguration -Name filename.pssc -RunAsCredential yourdomain\administrator
- You will ask for the credential for the user, enter it. Accept all change told by PS.
- You can test the config from a PS Console on YOUR computer : Enter-PSSession -ComputerName servername -ConfigurationName filename.pssc
- Tried : Get-ADUser yourusername
- After you validate it's worked, you need to create a new PSWA Authorization Rule : Add-PswaAuthorizationRule -UserName yourdomain\administrator -ComputerName yourserver -ConfigurationName yourfilename.pssc
- Go on the PSWA console login page, enter your User Name, Password, Computer Name and click on Optional connection settings.
- In Configuration Name, type the name of it. Its yourname.pssc
- Test like step 8.
I hope that will help you. I want to thank's again tommymaynard from powershell.org.
If you have any comments or questions, feel free to do it.
Have a good day !
No comments:
Post a Comment