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