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