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