Ok seems to be an nodejs things built on top of ionic/angular and Cordova(for cross-platform?).
The source code is located in build/www/main.js
The var TutorialPage class is interesting stuff.
Video seems to be embedded in a vg_Player(with a crossorigin) as expect, read mp4 file.
Code:
<video [vgMedia]="media" [vgDash]="source" [vgHls]="source" #media id="singleVideo" preload="auto" type="video/mp4" crossorigin playsinline>\n </video>\n </vg-player
And the play prototype is pretty explanatory
TutorialPage.prototype.play
Which download the source, and sign/unsign it
Code:
TutorialPage.prototype.play = function (video, autoplay, setCursor, customCursor) {
var _this = this;
this.source = '';
this.isBuffering = true;
this.disableControl = false;
((video.download.status == __WEBPACK_IMPORTED_MODULE_4__providers_download_status__["a" /* DownloadStatus */].STATUS_DOWNLOADED)
? video.download
.getPath(true)
.mergeMap(function (directory) {
var basePath = directory.basePath, filePath = directory.filePath;
return _this._signerService.isSigned(basePath + '/' + filePath.substr(1))
.mergeMap(function (isSigned) { return isSigned ? _this._signerService.unsign(basePath + '/' + filePath.substr(1)) : __WEBPACK_IMPORTED_MODULE_13_rxjs_Observable__["Observable"].of(''); })
.map(function () { return directory; });
})
.do(function (directory) {
var basePath = directory.basePath, filePath = directory.filePath;
var source = basePath + '/' + filePath.substr(1);
if (_this.device.platform === 'iOS') {
source = Object(__WEBPACK_IMPORTED_MODULE_2_ionic_angular__["I" /* normalizeURL */])(source);
}
_this._setSource(source, autoplay, video, setCursor, customCursor);
})
.do(function (directory) {
var basePath = directory.basePath, filePath = directory.filePath;
__WEBPACK_IMPORTED_MODULE_13_rxjs_Observable__["Observable"].timer(1000)
.mergeMap(function () { return _this._signerService.sign(basePath + '/' + filePath.substr(1), video.id); })
.subscribe(function () { return null; });
})
: this._videoService
.get(video.id)
.do(function (data) { return _this._setSource(data.link, autoplay, video, setCursor, customCursor); }))
.subscribe(function () {
_this.api.getDefaultMedia().loadMedia();
video.stats.lastTime = video.stats.cursor;
if (_this._completionSubscriber) {
_this._completionSubscriber.unsubscribe();
}
if (_this._playSubscriber) {
_this._playSubscriber.unsubscribe();
}
setTimeout(function () {
_this.onStartup = true;
_this._completionSubscriber = _this.api.getDefaultMedia().subscriptions.timeUpdate.subscribe(function () { return _this._updateStats(video); });
_this._playSubscriber = _this.api.getDefaultMedia().subscriptions.play.subscribe(function () { return _this._onPlay(video); });
}, 400);
});
};
But the sign module is a C++ module compiled in Tuto.com\node_modules\signer\build\Release\signer.node which is a C++ extension so will try to give a shot tonight to decompile it
At least there is the sln file (without the .cc that would have been too nice) but the PDB is still there so it should be pretty trivial.
Thanks for the support guys