iv-org / inv_sig_helper

GNU Affero General Public License v3.0
19 stars 4 forks source link

Generate potoken and visitordata from sig helper? #10

Open unixfox opened 1 month ago

unixfox commented 1 month ago

@techmetx11 someone found on how to generate poToken without a browser: https://github.com/YunzheZJU/youtube-po-token-generator

Do you think it would be somewhat possible to integrate this into sig helper project?

Cc @SamantazFox

techmetx11 commented 1 month ago

The program works by emulating the DOM API, intercepting JavaScript functions, and making a fake ytcfg object for it all to work. I'm going to figure out how to implement this within the program itself, It'll be a bit difficult since I have to somehow do it with QuickJS (rather than conveniently doing it within node.js)

unixfox commented 1 month ago

Yeah. I have looked too bad there is no way to use the npm library jsdom directly in rust.

There is a lookalike library in rust but it's probably incomplete: https://github.com/spider-rs/jsdom

techmetx11 commented 1 month ago

I've decided to just make inv_sig_helper run a extractor script written in Node.JS, and parse and return (maybe cache aswell) the result back to the users This means it'll be the slowest operation in the whole program, so I hope it'll only be ran occassionally or so

unixfox commented 1 month ago

Won't this make building for cross platform more difficult? How are you going to achieve this?

I was wondering if we could instead run the jsdom library using node from rust: https://austinpoor.com/blog/js-in-rs

techmetx11 commented 1 month ago

Won't this make building for cross platform more difficult? How are you going to achieve this?

I was wondering if we could instead run the jsdom library using node from rust: https://austinpoor.com/blog/js-in-rs

Nevermind, I'll figure out how to use Deno's runtime, although that means we'll have 2 JS interpreters inside the program

unixfox commented 1 month ago

@techmetx11 can you give us your matrix username? We would like to invite you to a private room for more in depth info about this implementation

techmetx11 commented 1 month ago

@techmetx11 can you give us your matrix username? We would like to invite you to a private room for more in depth info about this implementation

@techmetx11:digitalprivacy.diy