Readit News logoReadit News

Dead Comment

Dead Comment

Dead Comment

Dead Comment

Dead Comment

Dead Comment

oguz-ismail commented on Tarmageddon: RCE vulnerability highlights challenges of open source abandonware   edera.dev/stories/tarmage... · Posted by u/vsgherzi
dathinab · 4 months ago
(no specific order)

1. easy to create

2. easy to produce something with decent quality

3. rust is widely used by a lot of people, including juniors which don't know (yet) that it can be quite a pain to maintain a package and that it comes with some responsibility

4. so small hobby projects now can very easily become widely used dependencies as people looked at them and found them to have decent quality

5. currently "flat" package structure (i.e. no prefixes/grouping by org/project) there has been discussions for improving on it for a long time but it's not quite here yet. This matters as e.g. all "official" tokio packages are named tokio-* but thats also true for most 3rd party packages "specifically made for tokio". So `tokio-tar` is what you would expect the official "tokio" tar package to be named _if there where one_.

---

now the core problem of many unmaintained packages isn't that rust specific

it's just that rust is currently a common go to for young developers not yet burned by maintaining a package, it's supper easy to publish

on the other hand some of the previous "popular early carrier go to languages" had either not had a single "official" repo (Jave) or packaging was/is a quite a pain (python). Through you can find a lot of unmaintained packages in npm too, just it's so much easier to write clean decent looking code in rust that it's more likely that you use one in rust then in JS.

oguz-ismail · 4 months ago
> rust is widely used by a lot of people

it's used for rewriting CLI utilities with more color by five or so people

Dead Comment

oguz-ismail commented on Why Is SQLite Coded In C   sqlite.org/whyc.html... · Posted by u/plainOldText
dathinab · 4 months ago
> Had SQLite ever had a memory leak or use-after-delete bug on a production release?

sure, it's an old library they had pretty much anything (not because they don't know what they are doing but because shit happens)

lets check CVEs of the last few years:

- CVE-2025-29088 type confusion

- CVE-2025-29087 out of bounds write

- CVE-2025-7458 integer overflow, possible in optimized rust but test builds check for it

- CVE-2025-6965 memory corruption, rust might not have helped

- CVE-2025-3277 integer overflow, rust might have helped

- CVE-2024-0232 use after free

- CVE-2023-36191 segmentation violation, unclear if rust would have helped

- CVE-2023-7104 buffer overflow

- CVE-2022-46908 validation logic error

- CVE-2022-35737 array bounds overflow

- CVE-2021-45346 memory leak

...

as you can see the majority of CVEs of sqlite are much less likely in rust (but a rust sqlite impl. likely would use unsafe, so not impossible)

as a side note there being so many CVEs in 2025 seem to be related to better some companies (e.g. Google) having done quite a bit of fuzz testing of SQLite

other takeaways:

- 100% branch coverage is nice, but doesn't guarantee memory soundness in C

- given how deeply people look for CVEs in SQLite the number of CVEs found is not at all as bad as it might look

but also one final question:

SQLite uses some of the best C programmers out there, only they merge anything to the code, it had very limited degree of change compared to a typical company project. And we still have memory vulnerabilities. How is anyone still arguing for C for new projects?

oguz-ismail · 4 months ago
> How is anyone still arguing for C for new projects?

It just works

oguz-ismail commented on Modern Linux tools   ikrima.dev/dev-notes/linu... · Posted by u/randomint64
robenkleene · 4 months ago
Out of curiosity, how would you recursively grep files ignoring (hidden files [e.g., `.git`]), only matching a certain file extension? (E.g., `rg -g '*.foo' bar`.)

I use the command line a lot too and this is one of my most common commands, and I don't know of an elegant way to do it with the builtin Unix tools.

(And I have basically the same question for finding files matching a regex or glob [ignoring the stuff I obviously don't want], e.g., `fd '.foo.*'`.)

oguz-ismail · 4 months ago

    find . -name '.*?' -prune -o -name '*.foo' -exec grep bar /dev/null {} +
This is the POSIX way. You'd probably put it in a function in .bashrc

u/oguz-ismail

KarmaCake day-8June 17, 2024View Original