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