Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minimal change that allows proxying plugins/HeatmapSessionRecording/config.php. #35

Merged
merged 12 commits into from
Apr 17, 2018

Conversation

diosmosis
Copy link
Member

@diosmosis diosmosis commented Apr 10, 2018

Changes:

  • Allow target URL path to be specified outside of piwik.php.
  • Create config.php endpoint that includes piwik.php w/ $path set.

Fixes #26
Fixes #30
Fixes #36

@mattab
Copy link
Member

mattab commented Apr 11, 2018

FYI the file is called configs.php. To reproduce should be easy on localhost, you can create a Heatmap, then you should see your piwik.js file updated, and requests to your page will trigger the configs.php file.

@diosmosis
Copy link
Member Author

@mattab Tested locally, proxies to heatmap configs.php and query params are present in request.

@Findus23
Copy link
Member

@diosmosis

I just tried if it works to record Sessions and Heatmaps via the proxy and I am running across three issues:
(related to #30)

I am pretty sure this line:

tracker-proxy/piwik.php

Lines 91 to 93 in bdcb5d1

if(!isset($_GET['send_image']) || $_GET['send_image'] == 1) {
sendHeader("Content-Type: image/gif");
}

should read if(isset($_GET['send_image']) && $_GET['send_image'] == 1) {

Otherwise every request without an ?send_image will also be sent as an gif which seems to break the HSR plugin. Adding a JSON header would be even better, but with `Content-Type: text/html; charset=UTF-8" it also seems to work.


Now that the plugin has gotten the config it tries to send the clicked position via GET requests similar to this one:

http://localhost/tracker-proxy/piwik.php?hsr_vid=cPstId&hsr_ev[0][ti]=2650&hsr_ev[0][ty]=1&hsr_ev[0][s]=html&hsr_ev[0][x]=792&hsr_ev[0][y]=894&hsr_ev[1][ti]=2848&hsr_ev[1][ty]=1&hsr_ev[1][s]=html&hsr_ev[1][x]=910&hsr_ev[1][y]=820&hsr_ev[2][ti]=3050&hsr_ev[2][ty]=1&hsr_ev[2][s]=html&hsr_ev[2][x]=982&hsr_ev[2][y]=636&hsr_ev[3][ti]=3094&hsr_ev[3][ty]=2&hsr_ev[3][s]=html&hsr_ev[3][x]=984&hsr_ev[3][y]=632&hsr_ev[4][ti]=3254&hsr_ev[4][ty]=1&hsr_ev[4][s]=html&hsr_ev[4][x]=974&hsr_ev[4][y]=640&hsr_ev[5][ti]=3282&hsr_ev[5][ty]=1&hsr_ev[5][s]=html&hsr_ev[5][x]=974&hsr_ev[5][y]=646&hsr_ids[]=5&hsr_ids[]=6&hsr_vw=707&hsr_vh=977&hsr_ti=3814&hsr_smp=1000&hsr_fyp=1000&idsite=1&rec=1&r=396297&h=13&m=49&s=15&url=http://localhost/tracking.html&_id=730048d8cbaf722f&_idts=1523619036&_idvc=1&_idn=0&_refts=0&_viewts=1523619036&cs=windows-1252&send_image=1&cookie=1&res=1920x1080&gt_ms=2&pv_id=NrUMcI

But it seems like the part that tries to put the GET parameters back together fails, as PHP creates arrays out of them:
Warning: urlencode() expects parameter 1 to be string, array given in /home/lukas/public_html/tracker-proxy/piwik.php on line 95

A var_dump($value); seems to confirm this:

array (size=6)
  0 => 
    array (size=5)
      'ti' => string '2650' (length=4)
      'ty' => string '1' (length=1)
      's' => string 'html' (length=4)
      'x' => string '792' (length=3)
      'y' => string '894' (length=3)
  1 => 
    array (size=5)
      'ti' => string '2848' (length=4)
      'ty' => string '1' (length=1)
      's' => string 'html' (length=4)
      'x' => string '910' (length=3)
      'y' => string '820' (length=3)
  2 => 
    array (size=5)
      'ti' => string '3050' (length=4)
      'ty' => string '1' (length=1)
      's' => string 'html' (length=4)
      'x' => string '982' (length=3)
      'y' => string '636' (length=3)
  3 => 
    array (size=5)
      'ti' => string '3094' (length=4)
      'ty' => string '2' (length=1)
      's' => string 'html' (length=4)
      'x' => string '984' (length=3)
      'y' => string '632' (length=3)
  4 => 
    array (size=5)
      'ti' => string '3254' (length=4)
      'ty' => string '1' (length=1)
      's' => string 'html' (length=4)
      'x' => string '974' (length=3)
      'y' => string '640' (length=3)
  5 => 
    array (size=5)
      'ti' => string '3282' (length=4)
      'ty' => string '1' (length=1)
      's' => string 'html' (length=4)
      'x' => string '974' (length=3)
      'y' => string '646' (length=3)

There seems to be another issue:
On pageload the HSR-plugin sends a snapshot of the website via POST, which I think is completely unhandled and just returns the piwik.js:

hsr_vid=cPstId&hsr_ev[0][ty]=5&hsr_ev[0][ti]=0&hsr_ev[0][te]=%7B%22rootId%22%3A1%2C%22children%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A2%2C%22tagName%22%3A%22HTML%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A3%2C%22tagName%22%3A%22HEAD%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A4%2C%22tagName%22%3A%22SCRIPT%22%2C%22attributes%22%3A%7B%7D%7D%5D%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A5%2C%22tagName%22%3A%22BODY%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A6%2C%22tagName%22%3A%22H1%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A3%2C%22id%22%3A7%2C%22textContent%22%3A%22This%20is%20a%20Test%20page%22%7D%5D%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A8%2C%22textContent%22%3A%22%5Cn%5Cn%5Cn%5Cn%5Cn%22%7D%2C%7B%22nodeType%22%3A8%2C%22id%22%3A9%2C%22textContent%22%3A%22%20%22%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A10%2C%22textContent%22%3A%22%5Cn%22%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A11%2C%22tagName%22%3A%22SCRIPT%22%2C%22attributes%22%3A%7B%7D%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A12%2C%22tagName%22%3A%22SCRIPT%22%2C%22attributes%22%3A%7B%7D%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A13%2C%22textContent%22%3A%22%5Cn%22%7D%2C%7B%22nodeType%22%3A8%2C%22id%22%3A14%2C%22textContent%22%3A%22%20%22%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A15%2C%22textContent%22%3A%22%5Cn%5Cn%5Cn%22%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A16%2C%22tagName%22%3A%22STYLE%22%2C%22attributes%22%3A%7B%22type%22%3A%22text%2Fcss%22%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A3%2C%22id%22%3A17%2C%22textContent%22%3A%22%5Cn%20%20%20%20%2F*%20loading%20*%2F%5Cn%20%20%20%20.lt-sk-three-bounce%20%7B%5Cn%20%20%20%20%20%20margin%3A%202px%20auto%3B%5Cn%20%20%20%20%20%20width%3A%20100%25%3B%5Cn%20%20%20%20%20%20text-align%3A%20center%3B%20%7D%5Cn%20%20%20%20%20%20.lt-sk-three-bounce%20.lt-sk-child%20%7B%5Cn%20%20%20%20%20%20%20%20width%3A%205px%3B%5Cn%20%20%20%20%20%20%20%20height%3A%205px%3B%5Cn%20%20%20%20%20%20%20%20background-color%3A%20%23333%3B%5Cn%20%20%20%20%20%20%20%20border-radius%3A%20100%25%3B%5Cn%20%20%20%20%20%20%20%20display%3A%20inline-block%3B%5Cn%20%20%20%20%20%20%20%20-webkit-animation%3A%20lt-sk-three-bounce%201.4s%20ease-in-out%200s%20infinite%20both%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20animation%3A%20lt-sk-three-bounce%201.4s%20ease-in-out%200s%20infinite%20both%3B%20%7D%5Cn%20%20%20%20%20%20.lt-sk-three-bounce%20.lt-sk-bounce1%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-animation-delay%3A%20-0.32s%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20animation-delay%3A%20-0.32s%3B%20%7D%5Cn%20%20%20%20%20%20.lt-sk-three-bounce%20.lt-sk-bounce2%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-animation-delay%3A%20-0.16s%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20animation-delay%3A%20-0.16s%3B%20%7D%5Cn%5Cn%20%20%20%20%40-webkit-keyframes%20lt-sk-three-bounce%20%7B%5Cn%20%20%20%20%20%200%25%2C%2080%25%2C%20100%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(0)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(0)%3B%20%7D%5Cn%20%20%20%20%20%2040%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(1)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(1)%3B%20%7D%20%7D%5Cn%5Cn%20%20%20%20%40keyframes%20lt-sk-three-bounce%20%7B%5Cn%20%20%20%20%20%200%25%2C%2080%25%2C%20100%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(0)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(0)%3B%20%7D%5Cn%20%20%20%20%20%2040%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(1)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(1)%3B%20%7D%20%7D%5Cn%20%20%22%7D%5D%7D%5D%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A18%2C%22tagName%22%3A%22STYLE%22%2C%22attributes%22%3A%7B%22id%22%3A%22stylus-1%22%2C%22type%22%3A%22text%2Fcss%22%2C%22class%22%3A%22stylus%22%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A3%2C%22id%22%3A19%2C%22textContent%22%3A%22code%2C%5Cnpre%2C%5Cn.blob-code%20%7B%5Cn%20%20%20%20font-family%3A%20%5C%22Fira%20Code%20Retina%5C%22!important%3B%5Cn%7D%22%7D%5D%7D%5D%7D%5D%7D&hsr_ev[1][ty]=8&hsr_ev[1][dom]=%7B%22rootId%22%3A1%2C%22children%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A2%2C%22tagName%22%3A%22HTML%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A3%2C%22tagName%22%3A%22HEAD%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A4%2C%22tagName%22%3A%22SCRIPT%22%2C%22attributes%22%3A%7B%7D%7D%5D%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A5%2C%22tagName%22%3A%22BODY%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A1%2C%22id%22%3A6%2C%22tagName%22%3A%22H1%22%2C%22attributes%22%3A%7B%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A3%2C%22id%22%3A7%2C%22textContent%22%3A%22This%20is%20a%20Test%20page%22%7D%5D%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A8%2C%22textContent%22%3A%22%5Cn%5Cn%5Cn%5Cn%5Cn%22%7D%2C%7B%22nodeType%22%3A8%2C%22id%22%3A9%2C%22textContent%22%3A%22%20%22%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A10%2C%22textContent%22%3A%22%5Cn%22%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A11%2C%22tagName%22%3A%22SCRIPT%22%2C%22attributes%22%3A%7B%7D%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A12%2C%22tagName%22%3A%22SCRIPT%22%2C%22attributes%22%3A%7B%7D%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A13%2C%22textContent%22%3A%22%5Cn%22%7D%2C%7B%22nodeType%22%3A8%2C%22id%22%3A14%2C%22textContent%22%3A%22%20%22%7D%2C%7B%22nodeType%22%3A3%2C%22id%22%3A15%2C%22textContent%22%3A%22%5Cn%5Cn%5Cn%22%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A16%2C%22tagName%22%3A%22STYLE%22%2C%22attributes%22%3A%7B%22type%22%3A%22text%2Fcss%22%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A3%2C%22id%22%3A17%2C%22textContent%22%3A%22%5Cn%20%20%20%20%2F*%20loading%20*%2F%5Cn%20%20%20%20.lt-sk-three-bounce%20%7B%5Cn%20%20%20%20%20%20margin%3A%202px%20auto%3B%5Cn%20%20%20%20%20%20width%3A%20100%25%3B%5Cn%20%20%20%20%20%20text-align%3A%20center%3B%20%7D%5Cn%20%20%20%20%20%20.lt-sk-three-bounce%20.lt-sk-child%20%7B%5Cn%20%20%20%20%20%20%20%20width%3A%205px%3B%5Cn%20%20%20%20%20%20%20%20height%3A%205px%3B%5Cn%20%20%20%20%20%20%20%20background-color%3A%20%23333%3B%5Cn%20%20%20%20%20%20%20%20border-radius%3A%20100%25%3B%5Cn%20%20%20%20%20%20%20%20display%3A%20inline-block%3B%5Cn%20%20%20%20%20%20%20%20-webkit-animation%3A%20lt-sk-three-bounce%201.4s%20ease-in-out%200s%20infinite%20both%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20animation%3A%20lt-sk-three-bounce%201.4s%20ease-in-out%200s%20infinite%20both%3B%20%7D%5Cn%20%20%20%20%20%20.lt-sk-three-bounce%20.lt-sk-bounce1%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-animation-delay%3A%20-0.32s%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20animation-delay%3A%20-0.32s%3B%20%7D%5Cn%20%20%20%20%20%20.lt-sk-three-bounce%20.lt-sk-bounce2%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-animation-delay%3A%20-0.16s%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20animation-delay%3A%20-0.16s%3B%20%7D%5Cn%5Cn%20%20%20%20%40-webkit-keyframes%20lt-sk-three-bounce%20%7B%5Cn%20%20%20%20%20%200%25%2C%2080%25%2C%20100%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(0)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(0)%3B%20%7D%5Cn%20%20%20%20%20%2040%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(1)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(1)%3B%20%7D%20%7D%5Cn%5Cn%20%20%20%20%40keyframes%20lt-sk-three-bounce%20%7B%5Cn%20%20%20%20%20%200%25%2C%2080%25%2C%20100%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(0)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(0)%3B%20%7D%5Cn%20%20%20%20%20%2040%25%20%7B%5Cn%20%20%20%20%20%20%20%20-webkit-transform%3A%20scale(1)%3B%5Cn%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20transform%3A%20scale(1)%3B%20%7D%20%7D%5Cn%20%20%22%7D%5D%7D%5D%7D%2C%7B%22nodeType%22%3A1%2C%22id%22%3A18%2C%22tagName%22%3A%22STYLE%22%2C%22attributes%22%3A%7B%22id%22%3A%22stylus-1%22%2C%22type%22%3A%22text%2Fcss%22%2C%22class%22%3A%22stylus%22%7D%2C%22childNodes%22%3A%5B%7B%22nodeType%22%3A3%2C%22id%22%3A19%2C%22textContent%22%3A%22code%2C%5Cnpre%2C%5Cn.blob-code%20%7B%5Cn%20%20%20%20font-family%3A%20%5C%22Fira%20Code%20Retina%5C%22!important%3B%5Cn%7D%22%7D%5D%7D%5D%7D%5D%7D&hsr_ev[1][id]=5&hsr_ids[]=5&hsr_ids[]=6&hsr_vw=707&hsr_vh=977&hsr_ti=1274&hsr_smp=1000&hsr_fyp=1000&idsite=1&rec=1&r=724358&h=13&m=49&s=12&url=http%3A%2F%2Flocalhost%2Ftracking.html&_id=730048d8cbaf722f&_idts=1523619036&_idvc=1&_idn=0&_refts=0&_viewts=1523619036&cs=windows-1252&send_image=0&cookie=1&res=1920x1080&gt_ms=2&pv_id=NrUMcI

@diosmosis
Copy link
Member Author

@Findus23 thanks for testing and catching these issues, I’ll probably look into them today

…/configs.php and use http_build_query() in piwik.php so array query param values are correctly transformed.
@diosmosis
Copy link
Member Author

@Findus23 fixed the first two issues you mentioned, and wasn't able to reproduce the third (possibly because one of the other two changes fixed that). If you feel so inclined, would appreciate another test :)

Note: added a DISABLE_SEND_IMAGE constant that is set by the configs.php endpoint. Didn't go w/ checking for send_image == 0 since it appears when there's no send_image the script should default to sending the header. (My guess is that it's for the non-JS trackers which may just assume an image is coming back. Ie, don't want to break BC).

@diosmosis
Copy link
Member Author

@matomo-org/core-team could use another code review too

@Findus23
Copy link
Member

Findus23 commented Apr 14, 2018

@diosmosis
I tested it again and the second issue is solved reliably.
The first issue is also solved, but it would be nice to also solve #30. (Or at least document the DISABLE_SEND_IMAGE constant in the config.php, so one can simply turn it off during debugging.

So the HSR plugin is now getting the click data, but the third issue still persists.
The POST isn't forwarded and therefore the Heatmap can't show any Heatmaps as it doesn't have a "screenshot".

grafik

I also found a similar issue when testing: #36

@diosmosis
Copy link
Member Author

@Findus23 I might be able to look into #30 too.

I was seeing heatmap screenshots locally, not sure why they were working for me, but I'll investigate further.

@diosmosis
Copy link
Member Author

diosmosis commented Apr 14, 2018

Reproduced the POST issue finally, nice catch! Should be able to fix that + the sendBeacon issue in this PR. And probably #30.

…tent-type header returned by the actual endpoint (like a proxy).
@diosmosis
Copy link
Member Author

The heatmap POST should work and now the content-type header is simply forwarded from the result.

Needs another testing pass & code review.

Note: if the sendBeacon() request sends a POST, then it should work w/ this change, too, but I was unable to find a way to test it.

@Findus23
Copy link
Member

@diosmosis I tested it and everything seems to be working fine.
The beacon request is also forwarded correctly.

Now we only need to forward the OptOut-iFrame (#29) and I'd say that the proxy is up-to-date.

@diosmosis
Copy link
Member Author

Forwarding more headers now.

Note: #29 will require proxying index.php so I think it should go into a new PR.

piwik.php Outdated

foreach ($_GET as $key => $value) {
$url .= urlencode($key ). '=' . urlencode($value) . '&';
if (!isset($path)) {
Copy link
Member

Choose a reason for hiding this comment

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

We may need to init $path initially. I'm thinking of older PHP versions where it is possible to say like ?path=... and then it is available as a variable. It's not a huge risk but it would allow users to potentially call any file which may be for example IP restricted. But because the tracker proxy may be running in the same network etc the request would be allowed. As said, it is not really a big issue, but better be safe. May need to have a another file that is not directly executable which both configs.php and piwik.php can include or so.

Copy link
Member Author

Choose a reason for hiding this comment

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

An init.php file sounds good, just in case someone creates an executable config.php or something.

Copy link
Member Author

Choose a reason for hiding this comment

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

Setting $path in piwik.php (either directly or indirectly) doesn't work since it would overwrite the value set in, eg, configs.php. Solved this by renaming piwik.php => proxy.php & including that w/ $path set. So this way, it's never uninitialized.

piwik.php Outdated
@@ -182,7 +241,7 @@ function getHttpContentAndStatus($url, $timeout, $user_agent)

return array(
$content,
$httpStatus
$httpStatus,
Copy link
Member

Choose a reason for hiding this comment

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

there is a trailing comma, but not important

Copy link
Member Author

@diosmosis diosmosis Apr 16, 2018

Choose a reason for hiding this comment

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

Left when undoing a change. Will leave it for the blame.

@tsteur
Copy link
Member

tsteur commented Apr 16, 2018

Worked for me 👍 only left a comment otherwise

* @link http://piwik.org/faq/how-to/#faq_132
* @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
*/

Copy link
Member

Choose a reason for hiding this comment

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

can we maybe in the other two files, define a constant, and then do something like this?

if (!defined( 'MYVARIABLENAME')) {
    exit; // this file is not supposed to be accessed directly
}

Copy link
Member Author

Choose a reason for hiding this comment

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

Will do.

proxy.php Outdated

$content = str_replace($TOKEN_AUTH, '<token>', $content);
Copy link
Member

Choose a reason for hiding this comment

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

would this mess up with a set content-length? I wonder if we need to use something like str_pad() to keep the same length or adjust the content-length header?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah, would mess it up, will make the content-length dynamic.

@diosmosis diosmosis merged commit 5868421 into master Apr 17, 2018
@diosmosis diosmosis deleted the 26-heatmaps branch April 17, 2018 04:27
@innocraft-automation innocraft-automation removed this from the Current sprint milestone Jan 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
5 participants