Skip to content

[Finishes #108285908] proxy https assets - #5516

Merged
Bjvanminnen merged 1 commit into
stagingfrom
proxy
Nov 20, 2015
Merged

[Finishes #108285908] proxy https assets#5516
Bjvanminnen merged 1 commit into
stagingfrom
proxy

Conversation

@Bjvanminnen

Copy link
Copy Markdown
Contributor

Right now the following app-lab code will fail with a security because of cross-origin issues.

createCanvas("new",320,450);
setActiveCanvas("new");
drawImageURL("https://www.smartlivingnetwork.com/uploads/201312171639333947695767_e4715ed9d5_b.jpg", setData);


function setData(){
  var theData = getImageData(0,0,320,450);
  for(var i = 0; i < 320; i++){
    setRGB(theData,i,100,255,0,0,255);
  }
  putImageData(theData,0,0);
}

This PR fixes this by enabling proxying of https assets. Presumably there is some downside to doing this/some reason this wasn't done originally?

Tested that the above code works now with both http and https images.

@philbogle

Copy link
Copy Markdown
Contributor

LGTM

I see no downsides to proxying https assets as well as http, this was just an oversight in the initial implementation. Thanks for for fixing!

Bjvanminnen added a commit that referenced this pull request Nov 20, 2015
[Finishes #108285908] proxy https assets
@Bjvanminnen
Bjvanminnen merged commit b5dfdad into staging Nov 20, 2015
@Bjvanminnen
Bjvanminnen deleted the proxy branch November 20, 2015 17:52
deploy-code-org added a commit that referenced this pull request Nov 20, 2015
b5dfdad Merge pull request #5516 from code-dot-org/proxy (Bjvanminnen)
5f05aec Merge pull request #5541 from code-dot-org/fix-events-again (Caley Brock)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants