Except it's not, not really - it's hosted by Cloudflare which even requires you to enable JavaScript to pass.
Website hosted on a 24 year old Linux server
101–110 of 131 posts
Re: Website hosted on a 24 year old Linux server
#102Earlier quoted context omitted.
> All you need to store this kind of data is a simple file. You mostly likely need a WAL Mode SQLite database. Most of the time, it's way simpler that handling state handling in concurrent situations yourself. (also, bindings are often available - if not outright bundled by default - under most common languages) The "easy" way is all fun and games until your file is accessed in a concurrent fashion, and then your opt…
It can be much simpler if you're willing to write a couple lines of assembler: use an 8-byte file that contains one 64-bit counter, mmap() it, mlock() it, and use atomic CPU instructions to increment and read it.
Re: Website hosted on a 24 year old Linux server
#103Earlier quoted context omitted.
> b) just write blindly to file and pretend concurrecy doesn't exist This is likely what was done. Nobody really cares if a hit counter on a web page loses a few updates.
Given it's a single-threaded CPU, there's a fair chance the web server isn't concurrent anyway. Linux got proper POSIX thread support with NPTL only in 2002.
Re: Website hosted on a 24 year old Linux server
#104Earlier quoted context omitted.
> b) just write blindly to file and pretend concurrecy doesn't exist This is likely what was done. Nobody really cares if a hit counter on a web page loses a few updates.
Given it's a single-threaded CPU, there's a fair chance the web server isn't concurrent anyway. Linux got proper POSIX thread support with NPTL only in 2002.
Re: Website hosted on a 24 year old Linux server
#105Except it's not, not really - it's hosted by Cloudflare which even requires you to enable JavaScript to pass.
I've got a pentium 90 I occasionally turn on and I'll reply again when I do here. Hosting stuff from it is wildly taxing. It's on my internal network and I proxy it through apache over a raspberry pi. But it does genuinely serve content to the proxy - which does not cache it. The machine runs netbsd with apache and has 128MB of memory and, as a cheat I'll admit, uses a SD/IDE bridge device to go to an ATA/100 interfa…
Re: Website hosted on a 24 year old Linux server
#106Earlier quoted context omitted.
It can be much simpler if you're willing to write a couple lines of assembler: use an 8-byte file that contains one 64-bit counter, mmap() it, mlock() it, and use atomic CPU instructions to increment and read it.
Genuine question: Does it have to be mlocked for this to work?
Re: Website hosted on a 24 year old Linux server
#107Earlier quoted context omitted.
> Doing this in modern times would be so complicated. No, it wouldn't. All you need to store this kind of data is a simple file. Most people would probably use PHP for something like that due to its ubiquity, but it could even be a few lines of bash, or Python, or Go, or whatever...
> All you need to store this kind of data is a simple file. You mostly likely need a WAL Mode SQLite database. Most of the time, it's way simpler that handling state handling in concurrent situations yourself. (also, bindings are often available - if not outright bundled by default - under most common languages) The "easy" way is all fun and games until your file is accessed in a concurrent fashion, and then your opt…
Of course you have to make sure to not run out of diskspace or max file size of the OS/filesystem (2GB on a 32bit system?)
Re: Website hosted on a 24 year old Linux server
#108Earlier quoted context omitted.
> Doing this in modern times would be so complicated. No, it wouldn't. All you need to store this kind of data is a simple file. Most people would probably use PHP for something like that due to its ubiquity, but it could even be a few lines of bash, or Python, or Go, or whatever...
> All you need to store this kind of data is a simple file. You mostly likely need a WAL Mode SQLite database. Most of the time, it's way simpler that handling state handling in concurrent situations yourself. (also, bindings are often available - if not outright bundled by default - under most common languages) The "easy" way is all fun and games until your file is accessed in a concurrent fashion, and then your opt…
Re: Website hosted on a 24 year old Linux server
#109Earlier quoted context omitted.
I assumed myself there must be a lot of root privilege vulnerabilities in Apache, but it appears there isn't a single one: https://www.cvedetails.com/vulnerability-list.php?vendor_id=... All the above seem to be in other Apache products. I think the fact that Apache doesn't run as root helps to mitigate these risks. Having said that, I have had a server compromised (about 20 years ago), through apache, suexec and a v…
Don't get me wrong, I don't mean to recommend running ancient software and not caring about security! It was rather out of curiosity: for the past 20-something years, which is no guarantee for the future (especially with software getting more complex than ever), would there be a blanket issue if you follow best practices in general (like dropping ports in iptables if you don't need them), or is it only specific circu…
Re: Website hosted on a 24 year old Linux server
#110Except it's not, not really - it's hosted by Cloudflare which even requires you to enable JavaScript to pass.
I immediately close the browser tab every time I see the cloudflare spinner. Very few websites are worth supporting the massive MITM that is cloudflare.
You're not running arbitrary code on my machine without earning my trust first.