crypto
crypto
Explore posts from servers
CDCloudflare Developers
Created by crypto on 6/8/2024 in #pages-help
Migrated react app from firebase to pages, getting error e is null during runtime
I migrated my create react app from firebase to cloudflare pages but now it gives an error e is null. The build succeeds without any problem. It still depends on the firebase for authentication but that should not be an issue given it also works locally. I did not use npm create cloudflare@latest my-react-app -- --framework=react as I already have an existing codebase. Am I missing something? I also defined the env variable NODE_VERSION=20 since we are using 20.x.
1 replies
CC#
Created by crypto on 1/13/2024 in #help
Trying to manipulate the host header in C#
I can do it in python or other languages but I am trying to adopt C# for all my exploit developments. I am writing a PoC for a security bug and it requires me to modify the host header so that it overflows on the server. But it seems there is a maximum limit of 256 characters for host header in HttpClient itself. Here is the snippet:
using(HttpClient client = new HttpClient())
{
HttpRequestMessage request = new() {
RequestUri = new Uri($"http://{TARGET}/"),
Method = HttpMethod.Get,
};

request.Headers.Host = new string('a', 3000);
await client.SendAsync(request);
}
using(HttpClient client = new HttpClient())
{
HttpRequestMessage request = new() {
RequestUri = new Uri($"http://{TARGET}/"),
Method = HttpMethod.Get,
};

request.Headers.Host = new string('a', 3000);
await client.SendAsync(request);
}
This will throw an exception with message The specified value is not a valid 'Host' header string.. Is any way to set host header to very long strings in HttpClient? If not, is there any alternative in C#?
5 replies
CDCloudflare Developers
Created by crypto on 3/25/2023 in #pages-help
Update Zola version for Cloudflare Pages
I have a zola blog hackberry.pages.dev (https://hackberry.xyz) and recently I have included authors name on each blog post with authors field in page. However older versions of zola does not support it. With 0.17 running locally, I can see the authors and build succeeds but pages running v0.14 always fails to build it. I tried updating the version to v0.17 with env variable but zola needs latest glibc. Deployment ID: 96122e07-1e07-422f-9abe-a208efd2e4fc Account ID: 181fc56e6f7cfbf6a78b5a9df588ed6f (Not sure if this is correct ID) Can you please update Zola to the latest one or allow custom build scripts? Thank you.
8 replies