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