-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSSITAPCAdb0.ps1
More file actions
71 lines (71 loc) · 3.38 KB
/
SSITAPCAdb0.ps1
File metadata and controls
71 lines (71 loc) · 3.38 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
$ErrorActionPreference = "si"
function write-title(){
cls
write-host -f r "███████╗███████╗██╗████████╗ █████╗ ██████╗ ██████╗ █████╗ ██████╗ ██████╗
██╔════╝██╔════╝██║╚══██╔══╝██╔══██╗ ██╔══██╗██╔════╝██╔══██╗██╔══██╗██╔══██╗
███████╗███████╗██║ ██║ ███████║ ██████╔╝██║ ███████║██║ ██║██████╔╝
╚════██║╚════██║██║ ██║ ██╔══██║ ██╔═══╝ ██║ ██╔══██║██║ ██║██╔══██╗
███████║███████║██║ ██║ ██║ ██║ ██║ ╚██████╗██║ ██║██████╔╝██████╔╝
╚══════╝╚══════╝╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝╚═╝ ╚═╝╚═════╝ ╚═════╝ "
write-host -n -f c "Fatto da ";write-host -f blu -n "Katoylla ";write-host -n -f c "per ";write-host -f r -n "SSITA";write-host -n " (";write-host -f r -n "https://discord.gg/ssita";write-host ")"
}
write-title
$res = [System.Collections.Generic.List[PSObject]]::new()
$p="$env:windir\appcompat\pca\PcaGeneralDb0.txt"
if(!(test-path $p)){
write "File non trovato nella path: $p"
if(test-path "$env:windir\appcompat\pca"){
write "Cartella pca trovata verifica se i file sono stati eliminati o ne è stato modificato il nome"
}else{
write "Cartella pca non presente. Probabilmente dipende dal pc dell'utente prosegui con l'ss"
}
write-host "Sotto trovi lo status di pcasvc se è stoppato decidi se bannare per servizio stoppato"
gsv pcasvc
sleep 5
exit
}
$raw=gc $p -en Unicode
$cs=@()
$cp=@()
$raw|%{
$curr=$_ -split "\|";
$p=[System.Environment]::ExpandEnvironmentVariables($curr[2])
$n=split-path -le $p
write-host -n ("Verifica firma digitale per "+$p)
$pos=$cp.indexof($p)
if($pos -eq -1){
if(test-path $p){
if(test-path -patht l $p){
$f=(get-authenticodesignature $p).status
}else{
$f="La path punta a una cartella"
}
}else{
$f="Path non trovata"
}
$cp+=$p
$cs+=$f
write-host -f r " Nuovo file elaborato, numero di file trovati fino ad adesso --> $($cp.count)"
}else{
write-host -f r " File già elaborato in precedenza, ottimizzata la fase di controllo"
$f=$cs[$pos]
}
$res.add([pscustomobject]@{
ExecutionTime=$curr[0]
DigitalSignature=$f
FileName=$n
Path=$p
FileDescription=$curr[3]
SoftwareVendor=$curr[4]
FileVersion=$curr[5]
AmcacheProgramID=$curr[6]
ExitCode=$curr[7]
RunStatus=$curr[1]
})
}
write-title
for($i=0;$i -lt $cp.count;$i++){
write-host -n ($cp[$i]+" | ")
write-host -f red $cs[$i]
}
$res|ogv -t "PCA DataBase Parser | Fatto da Katoylla per SSITA (https://discord.gg/ssita) | valori trovati: $($res.count) | file trovati: $($cp.count) " -passthru