TheAxeDude / ZiniGo

Utility to backup magazines from the Zinio service as PDF, bypassing/Removing their DRM.
MIT License
49 stars 9 forks source link

Index out of range #18

Open BlackB846 opened 3 years ago

BlackB846 commented 3 years ago

Hi,

I just came across the following error:

Starting the application... panic: runtime error: index out of range [2] with length 0

goroutine 1 [running]: main.GetInitialToken(0x945980, 0xc0000ce008, 0xc0000cb3e8, 0x1) C:/projects/ZiniGo/Grabazine.go:247 +0x267 main.main() C:/projects/ZiniGo/Grabazine.go:72 +0x3af

I currently have 531 magazines in my library - is there a limitation?

Thanks.

Prizm4 commented 3 years ago

I get the same error. I only have one magazine in Zinio.

C:\zinigo>zinigo
Config file loaded
Username taken from config file
password taken from config file
chromepath taken from config file
Starting the application...
panic: runtime error: index out of range [2] with length 0

goroutine 1 [running]:
main.GetInitialToken(0x945980, 0xc000006018, 0xc00007f3e8, 0x1)
        C:/projects/ZiniGo/Grabazine.go:247 +0x267
main.main()
        C:/projects/ZiniGo/Grabazine.go:72 +0x3af
ghost commented 3 years ago

Code is looking for a JWT (auth token) in the HTML which isn’t there anymore. Looks like Zinio has changed their login process. Somebody will have to wire capture the latest Zinio desktop app to find the new URL they’re using.

TheAxeDude commented 3 years ago

Hi there, I will try take a look at this ASAP, hopefully they havent changed too much :)

TheAxeDude commented 3 years ago

I took a quick look, they've changed quite a bit - I'll try get a new working version ASAP.

TheAxeDude commented 3 years ago

Hi there,

I've published an updated version, using their new login mechanisms. https://github.com/TheAxeDude/ZiniGo/tree/master/built

Please let me know if you have any issues?

ghost commented 3 years ago

New version works for me on Linux/amd64. Can I also say thank you for your work on this program. It really is awesome.

BlackB846 commented 3 years ago

Unlike the previous versions, this one will not launch under Windows 10

TheAxeDude commented 3 years ago

@BlackB846 I've rebuilt the windows exe (and tested). Sorry about that!

BlackB846 commented 3 years ago

Thank you very much - works perfectly under current Win 10

ZalakainTheOne commented 3 years ago

Works fine, thanks!

SR-G commented 3 years ago

Surprinsigly i can't launch the latest binary under Linux :

./Zinigo_Linux_AMD64 
zsh: exec format error: ./Zinigo_Linux_AMD64

and indeed when opening it with an HEX editor, he header does not contain the expected ELF first bytes ...

In fact i think both files are MAC versions :

cksum Zinigo*
520078227 11627440 Zinigo_Linux_AMD64
520078227 11627440 Zinigo_Macos_AMD64

edit : hopefully a local compilation from "master" branch (which seems to include all these latest modifications) is easy (for reference, if anyone needs it ...) :

go mod init zinigo
go mod tidy
go build

but then i had to change the fileExists() method, it was generating a "panic: runtime error: invalid memory address or nil pointer dereference" error line 343 (return !info.IsDir())

After that, i confirm that it's everything is working fine, thanks !