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