You are here: Windows OS HubPowershell

Archive for the 'Powershell' Category

Using PowerShell Behind a Proxy

Posted on September 15th, 2017 · Posted in Powershell
Invoke-WebRequest: Unable to connect to the remote server

If you access the Internet in the organization via the proxy server, by default you won’t be able to access an external webpage (Invoke-WebRequest cmdlet), update help using Update-Help cmdlet or download an application package from an external package repository (using PackageManagement or NanoServerPackage) from your PowerShell session. In this.. read more

How to Find Blocked, Disabled or Inactive Objects in AD Using Search-ADAccount

Posted on September 6th, 2017 · Posted in Active Directory, Powershell
Search-ADAccount out-gridview

Quite an often task of an Active Directory administrator is to make a list of disabled or inactive accounts and computers, or a list of accounts with expired passwords. To do it, you can use either the saved LDAP queries in the ADUC console, or already familiar PowerShell cmdlets, like.. read more

How to Access and Manage Windows Registry with PowerShell

Posted on June 2nd, 2017 · Posted in Powershell
powershell create registry parameter

Starting from its first version, PowerShell offers an administrator an extensive set of tools to interact with Windows system registry. If necessary, all typical operations with the registry can be performed not in the good old  Regedit interface, or reg.exe, but in PowerShell command prompt. In different scripts and scenarios.. read more

PowerShell Remoting via WinRM for Non-Admin Users

Posted on April 25th, 2017 · Posted in Powershell
Set-PSSessionConfiguration-Name Microsoft.PowerShell-showSecurityDescriptorUI

By default, to connect to a remote computer using PowerShell (PowerShell Remoting) you need the administrator privileges. In this article we’ll show how to allow remote connection using PowerShell Remoting (WinRM) for common users (without the administrator privileges) with the help of a security group, a Group Policy and modification.. read more

How to Sign PowerShell Script with a Code Signing Certificate

Posted on January 25th, 2017 · Posted in Powershell
SIG Begin signature block

A script or an executable with a digital signature allows a user to make sure that a file is original and its code has not been changed by third parties. PowerShell also has an integrated feature to sign a *.ps1 script files.

Hyper-V PowerShell Direct in Windows Server 2016

Posted on January 19th, 2017 · Posted in Hyper-V, Powershell, Windows Server 2016
Managing Hyper-V 2016 VMs using PowerShell Direct

PowerShell Direct is a new PowerShell feature in Windows Server 2016 and Windows 10 that allows to create a direct local PowerShell session with any virtual machine run on a Hyper-V host, meanwhile the connection is established not via the network, but  through the internal VM bus. Thus, a Hyper-V.. read more

Checking TCP Port Response Using PowerShell

Posted on December 2nd, 2016 · Posted in Powershell
Test-NetConnection check remote tcp port

From time to time, any administrator has to check service availability on a remote server  by testing remote TCP port response. Meanwhile, everybody got used to doing it quickly using telnet command. For example, to make sure the SMTP service is response on a mail server (by default, it responds.. read more

How to Import User Photo to Active Directory Using PowerShell

Posted on November 18th, 2016 · Posted in Active Directory, Powershell
import user photo to ad

Among user attributes starting from the version of Active Directory schema in Windows Server 2000, there is a special attribute thumbnailPhoto, in which a user photo (or any other images) can be stored as binary data. Outlook since 2010, Lync, SharePoint (and other applications) can use the data contained in.. read more

Auditing Users Password Strength in AD

Posted on October 5th, 2016 · Posted in Active Directory, Powershell
Active Directory Password Quality Report

The complexity of a user password in Active Directory domain is one of the key security elements both for user data, and the entire domain. As a rule, users prefer to use weak, easy-to-remember passwords. Thus, they significantly reduce the level of protection against hackers for their accounts. In this.. read more

Tracking Files Deletion using Audit Policy and MSSQL

Posted on August 31st, 2016 · Posted in Powershell, Windows Server 2012 R2
select file deletion event from mysql db

Any Windows administrator has come across the situation when angry users want to know who has deleted a very important file of the annual report from the share on the file server. This information can be obtained only if you have enabled the audit of the deleted files and folders.. read more