﻿Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Get-Process -Name powershell
Get-ADUser -Filter 'Enabled -eq True'
Set-Location C:\\Temp
Get-FileHash -Path C:\\Windows\\System32\\notepad.exe -Algorithm SHA256
Get-Process -Name powershell
systeminfo
Get-ADPermission -Identity 'OU=BadOU,DC=novatech,DC=local' -User svc_backup
Write-Host 'Operation terminée'
Get-EventLog -LogName Application -Newest 50
Disconnect-PSDrive Z
Add-Content -Path C:\\Scripts\\deploy.ps1 -Value '# Deployment script updated'
Get-Credential
Get-Date
Invoke-WebRequest -Uri 'https://intranet.novatech.local' -UseDefaultCredentials
cls
Get-ADServiceAccount -Filter * -Properties *
Get-ADComputer -Filter *
Get-HotFix -Id KB5005565
Get-ADGroup -Filter *
Get-EventLog -LogName System -Newest 50
Get-ProcessMitigation -Name powershell.exe
Get-Service -Name WinRM | Format-List *
Get-ADGroup -Filter *
Disconnect-PSDrive Z
Get-ChildItem -Recurse C:\\Scripts\\
Get-EventLog -LogName Security -After (Get-Date).AddDays(-7) -InstanceId 4662 -Newest 100
Get-EventLog -LogName Security -InstanceId 4648 -Newest 100
Set-ExecutionPolicy RemoteSigned -Scope Process
Get-WmiObject Win32_OperatingSystem
Get-ADComputer -Filter *
Get-EventLog -LogName Security -InstanceId 4648 -Newest 100
whoami
Get-LocalGroupMember -Group 'Administrators'
Test-Connection -ComputerName dc01.novatech.local
Get-WmiObject -Class Win32_NetworkAdapterConfiguration | Format-Table Description,IPAddress,MACAddress
Write-Host 'Operation terminée'
Get-WmiObject Win32_Service | Where-Object {.StartMode -eq 'Auto'}
systeminfo
Get-ADUser -Filter 'Enabled -eq True'
hostname
Disconnect-PSDrive Z
Get-LocalGroupMember -Group 'Administrators'
Get-WmiObject Win32_Service | Where-Object {.StartMode -eq 'Auto'}
Get-ScheduledTaskInfo -TaskName 'DailyBackupJob'
Get-EventLog -LogName Application -After (Get-Date).AddDays(-1) -EntryType Error
Add-Content -Path C:\\Scripts\\deploy.ps1 -Value '# Deployment script updated'
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Get-EventLog -LogName Security -InstanceId 4648 -Newest 100
Get-Service -Name WinRM | Format-List *
Get-WmiObject -Class Win32_Process | Where-Object {.Name -like '*spoolsv*'}
Get-HotFix -Id KB5005565
Get-Service | Where-Object {.Name -like '*crypt*'}
Get-EventLog -LogName Security -Source Microsoft-Windows-Security-Auditing -Newest 200
cls
Get-EventLog -LogName Application -Newest 50
Restart-Service -Name 'WinRM'
Get-SmbOpenFile
Get-Credential
Get-WmiObject -Class Win32_NetworkAdapterConfiguration | Format-Table Description,IPAddress,MACAddress
Get-WinEvent -FilterHashtable @{LogName='Directory Service';Id=4662} -MaxEvents 50
Get-ADOrganizationalUnit -Filter *
Test-NetConnection google.com
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Restart-Service -Name 'WinRM'
Add-Content -Path C:\\Scripts\\deploy.ps1 -Value '# Deployment script updated'
Get-NetIPAddress
Get-ADGroupMember 'Domain Admins'
whoami
Test-NetConnection google.com
Get-WmiObject Win32_OperatingSystem
Write-Host 'Operation terminée'
hostname
Get-Process | Where-Object {.CPU -gt 100}
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Write-Host 'Operation terminée'
hostname
Get-ADUser svc_backup -Properties lastLogonTimestamp
Get-WmiObject Win32_OperatingSystem
Get-ADComputer -Filter *
Get-SmbOpenFile
Get-ADUser svc_backup -Properties lastLogonTimestamp
Get-WmiObject -Class Win32_Process | Where-Object {.Name -like '*spoolsv*'}
Get-ADUser -Filter 'Enabled -eq True'
Get-WmiObject Win32_Service | Where-Object {.StartMode -eq 'Auto'}
Remove-Item C:\\Temp\\old_log.log -Force
Get-NetFirewallRule | Where-Object {.Enabled -eq 'True'}
systeminfo
Get-NetIPAddress
Invoke-WebRequest -Uri 'https://intranet.novatech.local' -UseDefaultCredentials
Get-Credential
Get-SmbOpenFile
Get-ADUser -Filter 'Enabled -eq True'
Get-Service | Where-Object {.Name -like '*crypt*'}
Get-ProcessMitigation -Name powershell.exe
Get-WmiObject -Class Win32_NetworkAdapterConfiguration | Format-Table Description,IPAddress,MACAddress
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Set-Location C:\\Temp
Get-CimInstance -ClassName Win32_QuickFixEngineering
Get-Process -Name powershell
Get-Credential
Get-Acl -Path 'AD:\\OU=BadOU,DC=novatech,DC=local'
Get-NTFSAccess -Path C:\\SYSVOL
Get-ADPrincipalGroupMembership svc_backup
Get-Content C:\\Scripts\\deploy.ps1
Test-NetConnection google.com
Get-Content C:\\Scripts\\deploy.ps1
Get-NTFSAccess -Path C:\\SYSVOL
Get-EventLog -LogName Application -Newest 50
Get-Command -Module ActiveDirectory
Import-Module ActiveDirectory
Get-ADGroupMember 'Domain Admins'
Get-ProcessMitigation -Name powershell.exe
Disconnect-PSDrive Z
Get-ADObject -LDAPFilter '(objectCategory=computer)'
Get-CimInstance -ClassName Win32_QuickFixEngineering
Write-Host 'Operation terminée'
Get-LocalGroupMember -Group 'Administrators'
Restart-Service -Name 'WinRM'
Get-EventLog -LogName System -Newest 50
