Earlier quoted context omitted.
it's not that insane. i've been manually typing http requests in since before http/1.1 and the mandatory host header. it is insane to use it for anything serious (also the opposite, implementing webservers in bash), but for quick testing it's pretty great!
Why wouldn’t you use curl for the quick test?
TIL: You can make HTTP requests without curl using Bash /dev/TCP
81–90 of 255 posts
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#82Earlier quoted context omitted.
Yep :) I just find example.com easier to remember and quicker to type than any of the OS or browser makers own URLs like - http://captive.apple.com/ - http://connectivitycheck.gstatic.com/generate_204 - http://detectportal.brave-http-only.com/ Plus, it feels nice to depend on the reserved domain name example.com instead of relying on a domain that any one specific corporation has to maintain :D
Also http://detectportal.firefox.com . And http://neverssl.com was set up for this purpose while being a bit easier to remember :)
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#83Earlier quoted context omitted.
> The cool part about FROM scratch images is that you'll never have to update your base image to address CVEs. Only your software and its (compiled) dependencies. What's the benefit really, though? If you still need to be able to rapidly deploy a new image in response to a dependency CVE, what have you gained?
You've gained that happening much less frequently. The tradeoff is making every other problem harder to diagnose.
Add an ephemeral container to an already running pod, for example to add debugging utilities without restarting the pod.
https://kubernetes.io/docs/reference/kubectl/generated/kubec...
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#84Earlier quoted context omitted.
It seems pretty cool, but I am wondering if there's any drawback on just using images that support curl? I can't think of any and to me it's kinda a must have, even on production images
More than one ~500 employee company I've worked at has had security policies either encouraging or requiring the use of "distro-less" images - images with no OS components other than the absolute minimum required to run the application. For go binaries this meant literally nothing in the container apart from the executable. In theory it has a couple of benefits. You don't have to re-deploy your image to patch CVE's i…
Add an ephemeral container to an already running pod, for example to add debugging utilities without restarting the pod.
https://kubernetes.io/docs/reference/kubectl/generated/kubec...
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#85https://github.com/ksh93/ast-open-archive/blame/master/src/c...
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#86docker inspect -f '{{.State.Pid}}' container-name
# let's imagine that outputs 814538
nsenter -t 814538 -n curl example.com
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#87Earlier quoted context omitted.
This worries me. Some AI writing styles became mainstream; at first it was the em-dashes, now it’s “A, not B” patterns and excessive acknowledging. There will be more. Was grandparent comment written by an LLM? Or is this a human who copies a style they saw in a blog post, unaware that they’re copying an AI? Or is this a human who spent too much time talking to an AI and now they just talk like this? Or is this an or…
When learning a language, I've heard it's good to find a reference speaker, such as a prolific actor, and mimic them in order to absorb several aspects of what makes them sound authentic as a speaker, such as vocabulary, intonation, diction, pacing. For many in the next generation of language learners, this reference will be Claude.
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#88Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#89I ran into this while checking connectivity between containers on an internal Docker network where the image had neither curl nor wget. The main surprise was that Bash has /dev/tcp which lets you do the equivalent of an HTTP request with a bit of shell magic, for instance: exec 3 /dev/tcp/service/8642 printf 'GET /health HTTP/1.1\r\nHost: service\r\nConnection: close\r\n\r\n' >&3 cat Where `service` is just the hostn…
It seems pretty cool, but I am wondering if there's any drawback on just using images that support curl? I can't think of any and to me it's kinda a must have, even on production images
Re: TIL: You can make HTTP requests without curl using Bash /dev/TCP
#90Earlier quoted context omitted.
[flagged]
An old habit that unfortunately makes one indistinguishable from LLMs these days...
I remember when the "hacker vs. cracker" distinction went away because Hollywood co-opted the former and it became de facto "hacker == bad guy"