Skip to content
blog.KimConnect.com
Menu
Codes
Windows
Linux
Virtualization
Networking
Database
Category:
Codes
blog.KimConnect.com
>>
Codes
,
Networking
Read More
November 4, 2021
November 4, 2021
kimconnect
kimconnect
PowerShell: Check IP Conflicts of Computers in Active Directory
We have ran into issues where a group of virtual machines living on a DHCP…
0 Comments
Read More
November 4, 2021
November 4, 2021
kimconnect
kimconnect
How to Obtain Mac Address of Remote Computer
# PowerShell $computername='TESTSERVER' Get-CimInstance -ClassName Win32_NetworkAdapterConfiguration -Filter "IPEnabled='True'" -ComputerName $computername|Select-Object -Property MACAddress, Description # Sample…
0 Comments
Read More
November 3, 2021
November 3, 2021
kimconnect
kimconnect
PowerShell: Set PasswordNeverExpires on SamAccountName
Quick 1-liner Code $accounts=@( 'orange', 'apple', 'pear', 'dog', 'cat', 'dinosaur', 'chicken', 'cow', 'yomama', 'yodada' )…
0 Comments
Read More
November 3, 2021
November 3, 2021
kimconnect
kimconnect
Convert LastLogon Date From Number to Date Time
We have a case where our Admins have generated a CSV file with information about…
0 Comments
Read More
November 2, 2021
November 2, 2021
kimconnect
kimconnect
Quick & Useful Snippet to Set SSL TLS Protocol of PowerShell
$requiredTls='Tls12' $availableSslProtocols=[enum]::getnames([net.securityprotocoltype]) if([Net.ServicePointManager]::SecurityProtocol -notin $requiredTls -and $requiredTls -in $availableSslProtocols){ [Net.ServicePointManager]::SecurityProtocol=[Net.SecurityProtocolType]::$requiredTls }
0 Comments
Read More
November 2, 2021
November 2, 2021
kimconnect
kimconnect
An Exercise in Discover Whether an Active Directory Account Has RDP Access to Windows Bastion Hosts
Check Computers: $computernames='RDPSERVER01','RDPSERVER02','RDPSERVER03' invoke-command -computername $computernames {get-localgroupmember 'remote desktop users'}|select PSComputername,Name # Sample output PS…
0 Comments
Read More
November 1, 2021
November 1, 2021
kimconnect
kimconnect
Indications that Chocolatey is locked down
# System's version is less than vendor's current (Chocolatey v0.10.15) 0+000+00[LAX-WEB005]: PS C:\Users\testadmin\Documents> choco source…
0 Comments
Read More
October 31, 2021
October 31, 2021
kimconnect
kimconnect
How To Upgrade NextCloud 22.1.1 to 22.2.0 When Deployed with Kubernetes & Helm
Step 1: Navigate to nextcloud > html > edit version.php <?php $OC_Version = array(22,1,1,2); $OC_VersionString…
2 Comments
Read More
October 30, 2021
October 30, 2021
kimconnect
kimconnect
WordPress: How To Add Custom XML Sitemap to Yoast SEO
Step 1: Install Yoast SEO Step 2: Install Code Snippets Step 3: Add this Snippet…
0 Comments
Read More
October 30, 2021
October 30, 2021
kimconnect
kimconnect
Kubernetes: Cert-Manager x509 ECDSA verification failure
Symptoms Error from server (InternalError): error when creating "kimconnect-cert.yaml": Internal error occurred: failed calling webhook…
0 Comments
Read More
October 30, 2021
October 30, 2021
kimconnect
kimconnect
Kubernetes: Cert-Manager Certificate Request YAML Example
# Set variables certPrefix=kimconnect domainName=kimconnect.com domainName2=www.kimconnect.com serviceName=kimconnectblog-wordpress servicePort=8080 # Create a yaml file and create…
0 Comments
Read More
October 29, 2021
October 29, 2021
kimconnect
kimconnect
PowerShell: Obtain List of Hyper-V Hosts via Active Directory
# listHyperVHostsInForests.ps1 # Version: 0.03 function listHyperVHostsInForests{ # Ensure that AD management module is available…
0 Comments
Read More
October 29, 2021
October 29, 2021
kimconnect
kimconnect
Linux: How To Use Dig
Checking Name Server(s) kim@kim-linux:~$ dig @8.8.8.8 microsoft.com ; <<>> DiG 9.16.1-Ubuntu <<>> @8.8.8.8 microsoft.com ;…
0 Comments
Read More
October 28, 2021
October 28, 2021
kimconnect
kimconnect
Bash Shell: Rename Files – Prepend and Append
Pre-pending # Prepend any file that doesn't have the word "/thumbs_" in its full path…
0 Comments
Read More
October 28, 2021
October 28, 2021
kimconnect
kimconnect
PowerShell: Add User To Group in Active Directory
$userId='kimconnect' $groupName='Remote Desktop Users' function addUserToGroup($userId,$groupName){ $userExists=Get-ADGroupMember $groupName|?{$_.SamAccountName -eq $userId} if(!$userExists){ Add-ADGroupMember -Identity $groupName -Members…
0 Comments
Read More
October 28, 2021
October 28, 2021
kimconnect
kimconnect
Domain Name Records Overview: A-record, MX, DKIM, SPF, SRV
A RECORD (A-host): - What: address record (A-record) specifies the IP address(es) of a given…
0 Comments
Read More
October 23, 2021
October 23, 2021
kimconnect
kimconnect
How To Improve WordPress Website Rendering Speed
These are the recommended plug-ins to enable caching, database cleaning, image compressing, and minify codes…
0 Comments
Read More
October 23, 2021
October 23, 2021
kimconnect
kimconnect
Bash: How To Join Array With Comma Delimiter
# The following function joins an array of numbers # Limitation: the delimiter is expected…
0 Comments
Read More
October 22, 2021
October 22, 2021
kimconnect
kimconnect
PowerShell: Reset Active Directory User Password
# User input variables $adminUsername='intranet\kim-a' $adminPassword='SOMECOMPLEXPASSWORD' $userId='kim' $newPassword='SOMECOMPLEXPASSWORD' $domainController='intranet.kimconnect.com' # Auto-gen Variables $encryptedPassword=ConvertTo-SecureString $adminPassword -AsPlainText…
0 Comments
Read More
October 21, 2021
October 21, 2021
kimconnect
kimconnect
PowerShell: Notify Each User Before Password Expires
# This script email users basing on their password expiration dates # User input variables…
0 Comments
Posts navigation
Previous page
1
…
5
6
7
…
41
Next page
Search
Archives
October 2024
September 2024
August 2024
June 2024
May 2024
April 2024
March 2023
February 2023
January 2023
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
Meta
Register
Log in
Tag Cloud