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