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