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