A CredentialManager to safely provide sensitive credentials to the extractors in non-leaking way.
Expected behavior
// User sets cookie
player.credentials.set(CredentialType.YouTube, {
cookie: ...
});
// Extractor gets cookie
const { cookie } = await this.context.requestCredentials(CredentialType.YouTube)
// ^ this code should throw error if the extractor is not supposed to access the credential
// Capture actions
player.credentials.onAccessRequest((extractor) => {
// Validate extractor manually
return true // or false to disallow
});
Screenshots
N/A
Additional context
Fixes confusing behavior of current "ytdlOptions" as well as setting access tokens for other extractors
Describe the feature you would like
A CredentialManager to safely provide sensitive credentials to the extractors in non-leaking way.
Expected behavior
Screenshots
N/A
Additional context
Fixes confusing behavior of current "ytdlOptions" as well as setting access tokens for other extractors