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