Skip to content
This repository has been archived by the owner on Jan 4, 2019. It is now read-only.

Commit

Permalink
Fix secure cookies using http url
Browse files Browse the repository at this point in the history
  • Loading branch information
darkdh authored and bridiver committed Oct 4, 2017
1 parent b80850f commit 9f0f95a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions atom/browser/importer/profile_writer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -177,11 +177,11 @@ void ProfileWriter::AddCookies(
for (const ImportedCookieEntry& cookie_entry : cookies) {
base::DictionaryValue* cookie = new base::DictionaryValue();
base::string16 url;
if (cookie_entry.httponly) {
url.append(base::UTF8ToUTF16("http://"));
if (cookie_entry.secure) {
url.append(base::UTF8ToUTF16("https://"));
url.append(cookie_entry.host);
} else {
url.append(base::UTF8ToUTF16("https://"));
url.append(base::UTF8ToUTF16("http://"));
url.append(cookie_entry.host);
}
cookie->SetString("url", url);
Expand Down

1 comment on commit 9f0f95a

@bsclifton
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

++

Please sign in to comment.