CMD Cookies Requiring higher-than-admin Permission

Description of the issue: I am attempting to access the Brave Cookies through an Administrator CMD, however, I get permission errors.
How can this issue be reproduced?

  1. Install yt-dlp (it can use cookies)
  2. Run a download command with the parameter --cookies-from-browser brave
  3. Error

Expected result: The cookies get extracted

Brave Version( check About Brave): Version 1.64.122 Chromium: 123.0.6312.122 (Official Build) (64-bit)

Additional Information: The cookies that are being accessed are C:\Users\<USERNAME>\AppData\Local\BraveSoftware\Brave-Browser\User Data\Default\Network\Cookies. I am running Windows 10 Pro.

I tried running your command and was met with:

C:\Windows\system32>cd \Users\User\Desktop
C:\Users\User\Desktop> yt-dlp --cookies-from-browser brave https://www.youtube.com/watch?v=sclul5qesg0
Extracting cookies from brave
ERROR: Could not copy Chrome cookie database. See  https://github.com/yt-dlp/yt-dlp/issues/7271  for more info
ERROR: Could not copy Chrome cookie database. See  https://github.com/yt-dlp/yt-dlp/issues/7271  for more info

After skimming through the above gihub issue, I found that Brave (and Chromium based browsers) lock the cookie store when it runs.

The workaround is to close the browser before running the command:

C:\Users\Uran\Desktop>yt-dlp --cookies-from-browser brave https://www.youtube.com/watch?v=sclul5qesg0
Extracting cookies from brave
Extracted 1334 cookies from brave
[youtube] Extracting URL: https://www.youtube.com/watch?v=sclul5qesg0
[youtube] sclul5qesg0: Downloading webpage
[...]

You can also try other things mentioned in the linked GitHub issue, such as adding the --disable-features=LockProfileCookieDatabase parameter when running Brave, but I have not tested it.

If your output differs from mine, you can also try updating yt-dlp from the Admin CMD, as it may help in diagnosing similar issues in the future:

yt-dlp -U

Updated it and now it mirrors your output.

This did not solve my issue unfortunately.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.