You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I am having a bit of an issue with redbird proxy and trying to make it work with the following project: plan-player-analytics/Plan#1488 .
So first a little background, I currently have several domains running through my redbird setup all pointing to various web servers over a selection of machines connected via vlans using a mix of http and https.
I am currently trying to add Plan to the list of websites run through redbird however i get the following error: HPE_UNEXPECTED_CONTENT_LENGTH when loading the page. When looking in the console of redbird is see the following:
After talking to the developer of Plan and creating a ticket on their github (link above) it appears to be related to the headers, specifically redbird using: Transfer-encoding: where as plan uses: Content-Length.
Is anyone able to help with either solving the problem or advising how i can tap into the system to manipulate the request / response accordingly. Currently this is the code i am trying to run but as you can see it does not run in the above image:
proxy.register("example.net", "http://192.168.100.2:8804", {
ssl: {
key: "certs/example.net-key.pem",
cert: "certs/example.net-cert.pem",
},
//},{
onRequest: (req, res, target) => {
// called before forwarding is occurred, you can modify req.headers for example
// return undefined to forward to default target
console.log(target)
console.log("=================================================")
console.log(req)
console.log("=================================================")
console.log(res)
console.log("=================================================")
res.removeHeader('transfer-encoding'); // changing the header
}
});
It seems that the onRequest is never called and I dont seem to be able to find any good documentation on it either which is not helping matters.
Many thanks to anyone who can help. I really would prefer not to have to change my proxy over this.
The text was updated successfully, but these errors were encountered:
@jackmaresca that is correct, latest from npm. Given your comment can you tell me a github version/tag or commit version to work from if you know of a stable one?
Hello,
So I am having a bit of an issue with redbird proxy and trying to make it work with the following project: plan-player-analytics/Plan#1488 .
So first a little background, I currently have several domains running through my redbird setup all pointing to various web servers over a selection of machines connected via vlans using a mix of http and https.
I am currently trying to add Plan to the list of websites run through redbird however i get the following error:
HPE_UNEXPECTED_CONTENT_LENGTH
when loading the page. When looking in the console of redbird is see the following:After talking to the developer of Plan and creating a ticket on their github (link above) it appears to be related to the headers, specifically redbird using:
Transfer-encoding:
where as plan uses:Content-Length
.Is anyone able to help with either solving the problem or advising how i can tap into the system to manipulate the request / response accordingly. Currently this is the code i am trying to run but as you can see it does not run in the above image:
It seems that the onRequest is never called and I dont seem to be able to find any good documentation on it either which is not helping matters.
Many thanks to anyone who can help. I really would prefer not to have to change my proxy over this.
The text was updated successfully, but these errors were encountered: