Scoop-Spotify
Scoop-Spotify copied to clipboard
Spotify's built-in updater is **not** disabled
Maybe the cause which leads to #34. According to the Readme:
Spotify's built-in updater is disabled, and Scoop should be used to update it instead.
But I am asked to update within spotify:
I have latest spotify via scoop installed (and no other plugins from this repo):
λ scoop list | grep ify
spotify-latest 1.1.57.443.ga029a6c4 [spotify]
λ scoop update spotify-latest
spotify-latest: 1.1.57.443.ga029a6c4 (latest version)
Latest versions for all apps are installed! For more information try 'scoop status'
λ scoop status
Scoop is up to date.
Everything is ok!
There seems to be files from today after I opened Spotify a few hours ago:
λ ls -lah %LOCALAPPDATA%\Spotify\Update\
total 85M
drwxr-xr-x 1 Dionysius 197121 0 Apr 28 15:10 ./
drwxr-xr-x 1 Dionysius 197121 0 Apr 28 15:10 ../
-rwxr-xr-x 1 Dionysius 197121 85M Apr 28 15:10 spotify_installer-1.1.57.443.ga029a6c4-43.exe*
-rw-r--r-- 1 Dionysius 197121 172 Apr 28 15:10 update.json
λ date /T && time /T
28.04.2021
17:12
λ icacls %LOCALAPPDATA%\Spotify\Update\
C:\Users\Dionysius\AppData\Local\Spotify\Update\ NT-AUTORITÄT\SYSTEM:(I)(OI)(CI)(F)
VORDEFINIERT\Administratoren:(I)(OI)(CI)(F)
PC-Dionysius\Dionysius:(I)(OI)(CI)(F)
Successfully processed 1 files; Failed processing 0 files
don't mind I'm using unix-like commands from git-extensions
I've tried to reapply those 4 commands https://github.com/TheRandomLabs/Scoop-Spotify/blob/master/bucket/spotify-latest.json#L29-L32
λ icacls %LOCALAPPDATA%\Spotify\Update /reset /T
processed file: C:\Users\Dionysius\AppData\Local\Spotify\Update
processed file: C:\Users\Dionysius\AppData\Local\Spotify\Update\spotify_installer-1.1.57.443.ga029a6c4-43.exe
processed file: C:\Users\Dionysius\AppData\Local\Spotify\Update\update.json
Successfully processed 3 files; Failed processing 0 files
λ rm -rf %LOCALAPPDATA%\Spotify\Update
λ mkdir %LOCALAPPDATA%\Spotify\Update
λ icacls %LOCALAPPDATA%\Spotify\Update /deny Everyone:R
Everyone: No mapping between account names and security IDs was done.
Successfully processed 0 files; Failed processing 1 files
λ icacls %LOCALAPPDATA%\Spotify\Update
C:\Users\Dionysius\AppData\Local\Spotify\Update NT-AUTORITÄT\SYSTEM:(I)(OI)(CI)(F)
VORDEFINIERT\Administratoren:(I)(OI)(CI)(F)
PC-Dionysius\Dionysius:(I)(OI)(CI)(F)
Successfully processed 1 files; Failed processing 0 files
But it seems icacls %LOCALAPPDATA%\Spotify\Update /deny Everyone:R
does not work correctly
I think I found the cause. My Windows doesn't have a group Everyone
. Although I changed even the system language to English, it was initially German. So the correct group in my case is Jeder
.
This command seems to apply what the scoop installation script for spotify-latest
wants to do:
λ icacls %LOCALAPPDATA%\Spotify\Update /deny Jeder:R
processed file: C:\Users\Dionysius\AppData\Local\Spotify\Update
Successfully processed 1 files; Failed processing 0 files
λ icacls %LOCALAPPDATA%\Spotify\Update
C:\Users\Dionysius\AppData\Local\Spotify\Update Jeder:(DENY)(R)
NT-AUTORITÄT\SYSTEM:(I)(OI)(CI)(F)
VORDEFINIERT\Administratoren:(I)(OI)(CI)(F)
PC-Dionysius\Dionysius:(I)(OI)(CI)(F)
Successfully processed 1 files; Failed processing 0 files
This looks better now
So, how can we make the script system language independent?
According to https://docs.microsoft.com/en-us/troubleshoot/windows-server/identity/security-identifiers-in-windows
S-1-1-0 | Everyone | A group that includes all users, even anonymous users, and guests. Membership is controlled by the operating system.
It seems we should use an asterisk *
when working with SIDs: https://stackoverflow.com/a/25747561
So how about
λ icacls %LOCALAPPDATA%\Spotify\Update /reset /T
processed file: C:\Users\Dionysius\AppData\Local\Spotify\Update
Successfully processed 1 files; Failed processing 0 files
λ icacls %LOCALAPPDATA%\Spotify\Update
C:\Users\Dionysius\AppData\Local\Spotify\Update NT-AUTORITÄT\SYSTEM:(I)(OI)(CI)(F)
VORDEFINIERT\Administratoren:(I)(OI)(CI)(F)
PC-Dionysius\Dionysius:(I)(OI)(CI)(F)
Successfully processed 1 files; Failed processing 0 files
λ icacls %LOCALAPPDATA%\Spotify\Update /deny *S-1-1-0:R
processed file: C:\Users\Dionysius\AppData\Local\Spotify\Update
Successfully processed 1 files; Failed processing 0 files
λ icacls %LOCALAPPDATA%\Spotify\Update
C:\Users\Dionysius\AppData\Local\Spotify\Update Jeder:(DENY)(R)
NT-AUTORITÄT\SYSTEM:(I)(OI)(CI)(F)
VORDEFINIERT\Administratoren:(I)(OI)(CI)(F)
PC-Dionysius\Dionysius:(I)(OI)(CI)(F)
Successfully processed 1 files; Failed processing 0 files
That looks like it worked correctly.
@dionysius I've fixed this issue but since @TheRandomLabs is not responding I've forked this repo and added all the fixes there. Feel free to check it out if you still need it.