HNHacker News
TopNewBestAskShowJobs

alsadi

148 karma · joined September 6, 2016

submissionscomments
alsadi··on XZ backdoor: "It's RCE, not auth bypass, and gated/unreplayable."
Untill the entire scope of this is identified I suggest activating the kill switch

https://bcksp.blogspot.com/2024/03/how-to-disable-xz-backdoo...

alsadi··on Serving Files in Python: How FastAPI Failed Us
here I've eliminated uvicorn, nothing changed

https://gist.github.com/muayyad-alsadi/3a1e1cdbafca34df8b178...

alsadi··on Serving Files in Python: How FastAPI Failed Us
Many things have changed since the old days. In PEP 3333 sendfile is exposed as opposed to PEP 333 (so in the WSGI days they had no way of doing it, but in ASGI they can do it).

The assumption that nginx is always there no longer hold, specially in microservices, ex. Running behind haproxy (does not service static files) or running bechind cloud provides like AWS ALB.

alsadi··on Serving Files in Python: How FastAPI Failed Us
As I pointed out in my other comment, serving a static file should be a single call to a kernel routine called sendfile (sendfile in c or in python io.sendfile or loop.sendfile). No loop, no memory copy, no further context switch.

Again if you think I was not fair to fastapi, suggest a change to the fastapi part. Do not cripple the competing solution.

If you want believe the time is wasted by the introduction of uvicorn layer as opposed to pure python implementation, I can run the fastapi in pure python ASGI without that layer, it would be worse. Because you uvicorn is one of the best implements.

alsadi··on Serving Files in Python: How FastAPI Failed Us
BTW being ASGI is not excuse because ASGI spec (PEP 3333) have a section on how to expose and make use of sendfile kernel routine.

https://peps.python.org/pep-3333/#optional-platform-specific...

alsadi··on Serving Files in Python: How FastAPI Failed Us
I made it like that to be as fair as possible and as simple as possible. I've done other experiments with same results. If you think I was not fair to the fastapi part feel free to edit the fastapi part in the form of github gist. And give me the link.
alsadi··on Serving Files in Python: How FastAPI Failed Us
It's reported here and they suggest adding nginx with x-accel which is basically surrending.

https://github.com/tiangolo/fastapi/issues/5803

alsadi··on “Coding is basically just ifs and for loops.”
Computers are just infinite tape marked out into squares... (Turing machine). A pyramid is just a stack of cubic rocks.
alsadi··on Virtual DOM is pure overhead (2018)
I do agree. When I first see it I knew that. Comparing two sequences (actual dom and dom) to find diff is like O(n^2) and the assumption that dom ops is expensive is a lie (premature optimization). Dom ops on ids and classes and fragments is very fast. In most cases a slow dom is always a developer fault failing to use fragments.
alsadi··on How much faster is Redis at storing a blob of JSON compared to PostgreSQL? 16×
How about making it redis+msgpack vs. postgresql json-like?
alsadi··on Architecting Containers: Understanding User Space vs. Kernel Space (2015)
2015
alsadi··on Treat Medicines Like Netflix Treats Shows
We are big pharam, give us tons of money and hope that we cure you! We don't! we just treat you.
alsadi··on The CPython Bytecode Compiler Is Dumb
Some optimizations can be enabled

"python -OO -m compileall mydir"

But it's merely skipping comments and names

alsadi··on Tesla Model 3 Owners Vent About Polar Vortex Affecting Cars
I guess Prius is not affected. But Prius is borning.
alsadi··on Why does APT not use HTTPS?
> Kazakhstan forces their citizens to install government-issued certificate to use SSL.

So why debian/ubuntu vulnteer to remove this layer? Why doing the equivalent of installing random certs for every gov/isp on every user?

Yes, government can force someone to install it, but it won't use force on every single person.

alsadi··on Why does APT not use HTTPS?
This would have been prevented

https://www.debian.org/security/2019/dsa-4371

alsadi··on Why does APT not use HTTPS?
Those arguments are invalid. Because debian/ubuntu fail to use https regimes like egypt/syria can track people who try install tor and they can cherry-pick block repos based on package name.

I'm sorry for not liking your favorite color and distro. Please deal with it.

And btw they don't digitally sign their package too (they sign separated meta data file having checksum which is not equivalent of embeding signature inside the package and validate it).

Compare that to yum/rpm which use secure https and signed rpm and signed metadata (both the medium and the payload are secured)

alsadi··on Windows 98 Icons are Great (2015)
I miss redhat's bluecurve icons. https://www.deviantart.com/redrope/art/Bluecurve-Complete-Ic...
alsadi··on Algorithms, by Jeff Erickson
No, kufi is named after a city in what is now Iraq not Iran.

https://en.m.wikipedia.org/wiki/Kufa

alsadi··on Algorithms, by Jeff Erickson
it's a known calligraphy style called kufi, just google it.

https://www.google.com/search?q=arabic+calligraphy+kufi&clie...

alsadi··on Algorithms, by Jeff Erickson
no, it's very readable because it's a well known calligraphy called kufi as others have pointed out.
alsadi··on Algorithms, by Jeff Erickson
The logo on the right is the arabic letters of the word Algorithmi (al-Khwarizmi) the persian muslim scholar after him algorithms and logarithms were named
alsadi··on Google Has a Plan to Eliminate Mosquitoes
Start feeling sad for the birds that eat them.
alsadi··on VirtualBox E1000 Guest-to-Host Escape
I guess SELinux/SVirt would mitigate this
alsadi··on IBM acquires Red Hat
Many comments mistaken redhat as an OS company? They are not. IBM did not buy redhat to get RHEL.

They bought it for the hybrid cloud as clearly stated.

Redhat has openstack platform, cloud formation/manage iq, openshift, ansible, ceph, glusterfs, codeenvy (behind eclipse che),... Etc

alsadi··on IBM acquires Red Hat
Defeting aws not ms. And projects like ansible and cloud formation / manage iq are the weapons
alsadi··on 3D printers have ‘fingerprints,’ which could help trace guns, counterfeit goods
Seriously! It would be much easier to get an effective ak47 from black market than printing sub-par plastic useless gun.
alsadi··on This technology would spot a secret chip in seconds
> .. would spot ..

the article describe how to spot a supposed spying chip when it happens, but why they single China? Just replace it with Israel and the article would still valid.

alsadi··on About the ZipCPU
Not all fpgu are equal. Maybe this targets those with lower specs.
alsadi··on Redis is not “open core”
Red Hat is wrong example, both RHEL and Openstack has no secret sauce, it's all opensourced.
Page 1 of 4Next →