Get-SmbShare
Get-Command -Module ActiveDirectory
Get-Service | Where-Object {.Status -eq 'Running'}
Get-EventLog -LogName Application -Newest 50
Test-NetConnection google.com
Get-ADOrganizationalUnit -Filter *
Get-FileHash -Path C:\\Windows\\System32\\notepad.exe -Algorithm SHA256
ipconfig /all
Get-ADGroup -Filter *
Get-EventLog -LogName Application -After (Get-Date).AddDays(-1) -EntryType Error
Get-SmbSession
Get-ADPermission -Identity 'OU=BadOU,DC=novatech,DC=local' -User svc_backup
systeminfo
Get-FileHash -Path C:\\Windows\\System32\\notepad.exe -Algorithm SHA256
Get-ProcessMitigation -Name powershell.exe
Get-Content C:\\Users\\svc_backup\\AppData\\Local\\Temp\\deploy.log
Get-Content C:\\Users\\svc_backup\\AppData\\Local\\Temp\\deploy.log
Get-Content C:\\Scripts\\deploy.ps1
Get-SmbOpenFile
Get-ADServiceAccount -Filter * -Properties *
Get-Service | Where-Object {.Name -like '*crypt*'}
Get-CimInstance -ClassName Win32_QuickFixEngineering
Get-ProcessMitigation -Name powershell.exe
Add-Content -Path C:\\Scripts\\deploy.ps1 -Value '# Deployment script updated'
cls
Get-Process -Name powershell
Set-Location C:\\Temp
Test-Connection -ComputerName dc01.novatech.local
Get-Command -Module ActiveDirectory
Get-LocalGroupMember -Group 'Administrators'
Get-NetFirewallProfile
Get-ProcessMitigation -Name powershell.exe
Remove-Item C:\\Temp\\old_log.log -Force
Import-Module ActiveDirectory
Get-ScheduledTask
Get-ScheduledTask
Set-Location C:\\Temp
Import-Module ActiveDirectory
Get-NetFirewallProfile
Test-Connection -ComputerName dc01.novatech.local
Get-ADComputer -Filter *
Get-CimInstance -ClassName Win32_QuickFixEngineering
Import-Module ActiveDirectory
Get-ADOrganizationalUnit -Filter *
Get-ADGroupMember 'Domain Admins'
Get-Process | Where-Object {.CPU -gt 100}
Get-ProcessMitigation -Name powershell.exe
Get-EventLog -LogName System -Newest 50
Get-ScheduledTask
Get-EventLog -LogName System -Newest 50
Add-Content -Path C:\\Scripts\\deploy.ps1 -Value '# Deployment script updated'
Get-Date
New-Item -Path C:\\Temp -ItemType Directory
Get-SmbOpenFile
Get-EventLog -LogName Security -Source Microsoft-Windows-Security-Auditing -Newest 200
Get-Acl -Path 'AD:\\OU=BadOU,DC=novatech,DC=local'
Get-Service | Where-Object {.Status -eq 'Running'}
Invoke-WebRequest -Uri 'https://intranet.novatech.local' -UseDefaultCredentials
Invoke-WebRequest -Uri 'https://intranet.novatech.local' -UseDefaultCredentials
Get-FileHash -Path C:\\Windows\\System32\\notepad.exe -Algorithm SHA256
New-PSDrive -Name Z -PSProvider FileSystem -Root \\\\DC01\\SYSVOL
Get-CimInstance -ClassName Win32_QuickFixEngineering
Get-ADPermission -Identity 'OU=BadOU,DC=novatech,DC=local' -User svc_backup
Get-WinEvent -FilterHashtable @{LogName='Directory Service';Id=4662} -MaxEvents 50
Get-ADUser svc_backup -Properties lastLogonTimestamp
Write-Host 'Operation terminée'
Restart-Service -Name 'WinRM'
Get-Content C:\\Scripts\\deploy.ps1
Get-WmiObject Win32_Service | Where-Object {.StartMode -eq 'Auto'}
Get-Date
Restart-Service -Name 'WinRM'
Get-NetIPAddress
Get-Process | Where-Object {.CPU -gt 100}
Get-Credential
Get-Date
Get-WmiObject Win32_Service | Where-Object {.StartMode -eq 'Auto'}
Get-Date
Get-ADGroupMember 'Domain Admins'
Get-Service | Where-Object {.Status -eq 'Running'}
Get-ADComputer -Filter *
cls
Get-NetFirewallRule | Where-Object {.Enabled -eq 'True'}
cls
New-PSDrive -Name Z -PSProvider FileSystem -Root \\\\DC01\\SYSVOL
Get-ADUser -Filter 'Enabled -eq True'
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Set-ExecutionPolicy RemoteSigned -Scope Process
Get-Process | Where-Object {.CPU -gt 100}
Get-SmbShare
Get-WinEvent -FilterHashtable @{LogName='Directory Service';Id=4662} -MaxEvents 50
Get-Service | Where-Object {.Status -eq 'Running'}
systeminfo
Write-Host 'Operation terminée'
Invoke-Command -ComputerName DC01 -ScriptBlock { gpupdate /force }
Get-ProcessMitigation -Name powershell.exe
New-PSDrive -Name Z -PSProvider FileSystem -Root \\\\DC01\\SYSVOL
Get-Date
Get-ADOrganizationalUnit -Filter *
Get-Command -Module ActiveDirectory
systeminfo
Get-SmbOpenFile
Copy-Item -Path C:\\Temp\\* -Destination Z:\\Backup\\
Get-CimInstance -ClassName Win32_QuickFixEngineering
Get-EventLog -LogName Application -Newest 50
New-Item -Path C:\\Temp -ItemType Directory
Get-EventLog -LogName Application -Newest 50
Set-Location C:\\Temp
Get-ProcessMitigation -Name powershell.exe
Get-Content C:\\Users\\svc_backup\\AppData\\Local\\Temp\\deploy.log
Invoke-WebRequest -Uri 'https://intranet.novatech.local' -UseDefaultCredentials
Invoke-WebRequest -Uri 'https://intranet.novatech.local' -UseDefaultCredentials
hostname
Get-ADServiceAccount -Filter * -Properties *
systeminfo
Set-ExecutionPolicy RemoteSigned -Scope Process
Get-ADUser svc_backup -Properties lastLogonTimestamp
Set-Location C:\\Temp
Add-Content -Path C:\\Scripts\\deploy.ps1 -Value '# Deployment script updated'
Get-SmbSession
