Decryption problem when using linux cookies on windows

Keywords: python linux windows selenium-chromedriver

Question: 

When I try to use Cookies file (sqlite fomatted) on Linux (Ubuntu) and Windows I fall into troubles with decryption of 'encrypted_value'. Is there any chance to make Cookies file compatible with two systems?

Basically selenium driver use Cookies file for various purpouses, and everything works on Linux. Sometimes my action is needed, so I want to have this Cookies file on my desktop which works on Windows, but when I download it directly and copy-paste it to my profile directory, my chromedriver logs error:

[4708:4884:0604/082853.607:ERROR:os_crypt_win.cc(61)] Failed to decrypt: The parameter is incorrect. (0x57)

I assume that there is some problem with 'encrypted_value' column decryption but I am unable to work-around this issue.

I use selenium for python this is snippet where I create options for my webdriver:

def create_options_for_webdriver(session_directory):
    print('Creating options for webdriver!')
    options = Options()
    options.add_argument("user-data-dir=my_userdir")
    options.add_argument("user-agent=my_useragent")
    options.add_argument('--disable-background-networking ')
    options.add_argument('--disable-client-side-phishing-detection')
    options.add_argument('--disable-default-apps')
    options.add_argument('--disable-hang-monitor')
    options.add_argument('--disable-popup-blocking')
    options.add_argument('--disable-prompt-on-repost')
    options.add_argument('--disable-sync')
    options.add_argument('--disable-web-resources')
    options.add_argument('--enable-automation')
    options.add_argument('--enable-blink-features=ShadowDOMV0')
    options.add_argument('--force-fieldtrials=SiteIsolationExtensions/Control')
    options.add_argument('--ignore-certificate-errors')
    options.add_argument('--no-first-run')
    options.add_argument('--password-store=basic')
    options.add_argument('--use-mock-keychain')
    return options

before option creating I create minimal directory structure which looks like my_userdir/Default/, and I download Cookies file to Default folder.

Answers: