Get-ProcessMitigation -Name powershell.exe
Get-EventLog -LogName Security -InstanceId 4648 -Newest 100
Start-Sleep -Seconds 10
Import-Module ActiveDirectory
Get-SmbShare
Get-ADOrganizationalUnit -Filter *
Get-ADGroupMember 'Domain Admins'
Get-EventLog -LogName Application -After (Get-Date).AddDays(-1) -EntryType Error
Copy-Item -Path C:\\Temp\\* -Destination Z:\\Backup\\
New-PSDrive -Name Z -PSProvider FileSystem -Root \\\\DC01\\SYSVOL
Get-ScheduledTask
Get-ADUser -Filter 'Enabled -eq True'
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Get-CimInstance -ClassName Win32_QuickFixEngineering
Get-WmiObject Win32_OperatingSystem
Get-SmbShare
Get-EventLog -LogName Security -After (Get-Date).AddDays(-7) -InstanceId 4662 -Newest 100
Get-ScheduledTask
Disconnect-PSDrive Z
Get-ScheduledTask
Get-WmiObject Win32_OperatingSystem
Get-EventLog -LogName System -Newest 50
Get-EventLog -LogName Application -Newest 50
Get-SmbOpenFile
Get-EventLog -LogName Application -After (Get-Date).AddDays(-1) -EntryType Error
Get-EventLog -LogName Application -After (Get-Date).AddDays(-1) -EntryType Error
Get-NTFSAccess -Path C:\\SYSVOL
Test-NetConnection google.com
Get-ADPrincipalGroupMembership svc_backup
Invoke-Command -ComputerName DC01 -ScriptBlock { gpupdate /force }
Get-WinEvent -FilterHashtable @{LogName='Directory Service';Id=4662} -MaxEvents 50
Restart-Service -Name 'WinRM'
Get-NTFSAccess -Path C:\\SYSVOL
Get-ScheduledTaskInfo -TaskName 'DailyBackupJob'
Test-NetConnection google.com
Test-NetConnection google.com
Get-EventLog -LogName Application -After (Get-Date).AddDays(-1) -EntryType Error
Get-Date
Get-Process -Name powershell
whoami
Set-Location C:\\Temp
Get-Service | Where-Object {.Name -like '*crypt*'}
Get-SmbSession
whoami
Get-LocalGroupMember -Group 'Administrators'
Get-NetIPAddress
Get-Acl -Path 'AD:\\OU=BadOU,DC=novatech,DC=local'
Get-EventLog -LogName System -Newest 50
Get-WmiObject Win32_Service | Where-Object {.StartMode -eq 'Auto'}
New-Item -Path C:\\Temp -ItemType Directory
cls
Get-SmbSession
Get-NetFirewallRule | Where-Object {.Enabled -eq 'True'}
Get-ADUser -Filter 'Enabled -eq True'
Copy-Item -Path C:\\Temp\\* -Destination Z:\\Backup\\
Get-Date
Get-WinEvent -FilterHashtable @{LogName='Directory Service';Id=4662} -MaxEvents 50
Get-ADGroupMember 'Domain Admins'
Get-ADUser svc_backup -Properties lastLogonTimestamp
Get-ADGroup -Filter *
Get-ADUser svc_backup -Properties lastLogonTimestamp
Get-ADUser -Filter 'Enabled -eq True'
Get-Content C:\\Users\\svc_backup\\AppData\\Local\\Temp\\deploy.log
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Get-ADComputer -Filter *
Get-ADServiceAccount -Filter * -Properties *
cls
Get-ADServiceAccount -Filter * -Properties *
New-Item -Path C:\\Temp -ItemType Directory
Get-NetFirewallProfile
Set-Location C:\\Temp
Get-Service -Name WinRM | Format-List *
systeminfo
Get-Content C:\\Users\\svc_backup\\AppData\\Local\\Temp\\deploy.log
Get-LocalGroupMember -Group 'Administrators'
New-PSDrive -Name Z -PSProvider FileSystem -Root \\\\DC01\\SYSVOL
Get-ScheduledTaskInfo -TaskName 'DailyBackupJob'
Get-ScheduledTask
Start-Sleep -Seconds 10
Remove-Item C:\\Temp\\old_log.log -Force
hostname
Get-ScheduledTaskInfo -TaskName 'DailyBackupJob'
Get-ADPermission -Identity 'OU=BadOU,DC=novatech,DC=local' -User svc_backup
Get-LocalGroupMember -Group 'Administrators'
Import-Module ActiveDirectory
Get-CimInstance -ClassName Win32_QuickFixEngineering
Start-Sleep -Seconds 10
Get-Service | Where-Object {.Status -eq 'Running'}
Get-NTFSAccess -Path C:\\SYSVOL
Get-ADPermission -Identity 'OU=BadOU,DC=novatech,DC=local' -User svc_backup
Get-LocalGroupMember -Group 'Administrators'
cls
Get-EventLog -LogName Security -InstanceId 4672 -Newest 50
Get-NetIPAddress
Get-Credential
Get-ScheduledTaskInfo -TaskName 'DailyBackupJob'
Get-NetFirewallRule | Where-Object {.Enabled -eq 'True'}
Get-WmiObject Win32_Service | Where-Object {.StartMode -eq 'Auto'}
Get-ADGroup -Filter *
Set-Location C:\\Temp
Get-SmbShare
Set-Location C:\\Temp
Get-Date
Get-ADUser -Filter 'Enabled -eq True'
Get-WmiObject -Class Win32_Process | Where-Object {.Name -like '*spoolsv*'}
Get-WmiObject Win32_OperatingSystem
Get-ADPrincipalGroupMembership svc_backup
Get-ADGroup -Filter *
Write-Host 'Operation terminée'
Get-CimInstance -ClassName Win32_QuickFixEngineering
Get-ADOrganizationalUnit -Filter *
Get-WmiObject -Class Win32_Process | Where-Object {.Name -like '*spoolsv*'}
Get-ADUser -Filter 'Enabled -eq True'
cls
Import-Module ActiveDirectory
Set-ExecutionPolicy RemoteSigned -Scope Process
New-PSDrive -Name Z -PSProvider FileSystem -Root \\\\DC01\\SYSVOL
Get-NetFirewallRule | Where-Object {.Enabled -eq 'True'}
Get-ADComputer -Filter *
Invoke-WebRequest -Uri 'https://intranet.novatech.local' -UseDefaultCredentials
