@hvangalen@mastodon.nl
@hvangalen@mastodon.nl avatar

hvangalen

@hvangalen@mastodon.nl

coder • (retro)techy • 3d printing • electronics • linux • casual gamer

I make & break stuff

toots are in English and Nederlands

wear a mask, stay safe

#nobot should keep the bots at bay

This profile is from a federated server and may be incomplete. Browse more on the original instance.

SuitedUpDev, to random
@SuitedUpDev@mastodon.online avatar

I am currently, de-compiling MIPS binaries for Linux.

Because apparently my life isn't horrible enough. 😩

hvangalen,
@hvangalen@mastodon.nl avatar

@SuitedUpDev Ooooh interesting.

It appears this is not the beginning of the file, as it references variables that I don't see the values of.

It's always tricky to reconstruct original code because compilers often do weird optimisation, compiling with -O3 and stripping the binary effectively makes it VeryHard™️ (but not impossible).

It appears to be copying the list of extensions somewhere, probably to filter it after the opendir() further down.

WTF are 0x405ad0 and 0x2e206765? LOL

hvangalen,
@hvangalen@mastodon.nl avatar

@SuitedUpDev It is also doing a weird copy because, why first stuff the bytes into uVar16,15 and 14 in stead of putting them into puVar13 directly (*puVar13 = *puVar6 is equivalent to puVar13[0] = puVar6[0]).

So I'm not sure any more this really is optimisations or just crappy code.

(And, the +4 makes no sense with 4 letter extensions and the + 7 surely is weird, especially with only the code in the screenshot)

hvangalen,
@hvangalen@mastodon.nl avatar

@SuitedUpDev Indeed, likely crap code. The case issue was even noticed by @knuppelbeer and they know fsck all about code. 😅

I'll have a peek at the pastebin.

hvangalen,
@hvangalen@mastodon.nl avatar

@SuitedUpDev Aha, this constructs the JSON response for the file list in some webbased GUI, and not bothering about escaping quotes in the actual file names.

hvangalen,
@hvangalen@mastodon.nl avatar

@knuppelbeer Eigenlijk hè, is dat wel voldoende basiskennis.

@SuitedUpDev

hvangalen,
@hvangalen@mastodon.nl avatar

@SuitedUpDev More evidence for lousy code:

auStack_161 is initialised, zeroed out and not used in any way.

hvangalen,
@hvangalen@mastodon.nl avatar

@SuitedUpDev From line 119 it grabs the extension of the file and then tries to find that in local_2d0 (the earlier string constructed/copied from the list of extensions).

So yeah, definitely a filter and they could've used strcasestr().

hvangalen,
@hvangalen@mastodon.nl avatar

@SuitedUpDev Oh, and a potentially exploitable crash if readdir did not assign d_type (is set to 0 on some filesystems, and an additional stat() call is required to get the type information via stat()).

It then uses sprintf() [tsk tsk] to create the path for the __lxstat() call, and if directory name + file name are larger than 1023 bytes this overflows.

Though whether this can be triggered depends on filesystem.

CODE SMELL LIKE 8 WEEK OLD UNWASHED FEET

hvangalen, to random Dutch
@hvangalen@mastodon.nl avatar

Je kunt er de klok op gelijk zetten dat de """anti-cancel-culture""", de """vrijheid-van-meningsuiting" en """anti-woke""" partijen over een paar maanden dingen gaan proberen te verbieden.

MrLovenstein, to random
@MrLovenstein@mastodon.social avatar

Secret Panel HERE 💥 https://tapas.io/episode/3005249

hvangalen,
@hvangalen@mastodon.nl avatar

@MrLovenstein Enable subtitles. Problem solved.

knuppelbeer, to random Dutch
@knuppelbeer@mastodon.social avatar

toen ik vroeger ooit eens bij de Kwantum werkte liep ik telkens tegen de lamp 😬

hvangalen,
@hvangalen@mastodon.nl avatar

@knuppelbeer Een beer in de Praxis. Ik geloof er /niets/ van!

hvangalen,
@hvangalen@mastodon.nl avatar

@knuppelbeer Sure alleen een beer kan zo'n irritante route verzinnen dat ieder mens in de val doet lopen.

hvangalen, to animals
@hvangalen@mastodon.nl avatar
hvangalen, to animals
@hvangalen@mastodon.nl avatar
epso, to random Dutch
@epso@mstdn.social avatar

de nieuwe Dune films gekeken en ik ben fan ❤️

hvangalen,
@hvangalen@mastodon.nl avatar

@epso Grappig hoe smaken verschillen. 😁

Ik was echt /zo/ ongelooflijk underwhelmed van de eerste.

Het beste aan de film vond ik de CGI. Het verhaal, het acteerwerk, ik vond het allemaal erg voorspelbaar, saai en stom.

Misschien dat 2 het uit dat dal kan trekken maar ik zal er weer met lage verwachtingen instappen dan kan het alleen maar meevallen.

</NegativeOuweZak> 😅

hvangalen,
@hvangalen@mastodon.nl avatar

@simondh Dit is /precies/ wat ik aan de eerste al vond mankeren.

hvangalen,
@hvangalen@mastodon.nl avatar

@simondh Wat dat betreft hè, vond ik zelfs Rebel Moon van Zack Snyder leuker (en ja, die was ook slecht). 😁

dgar, to random
@dgar@aus.social avatar

Koalas aren’t bears.

Even though they’re koalafied, they failed bearification.

hvangalen,
@hvangalen@mastodon.nl avatar

@dgar Makes sense.

A single specimen is a koalonely.

@DocBohn

hvangalen, to animals
@hvangalen@mastodon.nl avatar
hvangalen, to animals
@hvangalen@mastodon.nl avatar
epso, to random Dutch
@epso@mstdn.social avatar

Grote lol in de koffie en thee winkel omdat er geen bon meer bij hoeft omdat ik het van de nieuwe strenge accountant niet meer mag aftrekken 😭

hvangalen,
@hvangalen@mastodon.nl avatar

@epso Huh ik doe dit al bijna 10 jaar.

hvangalen,
@hvangalen@mastodon.nl avatar

@simondh Ja lekker dan, toch eens navragen hoe dat zit, misschien begrijp ik iets verkeerd hoor, want er zitten wel aardig wat supermarktbonnetjes in mijn administratie.

@epso

hvangalen,
@hvangalen@mastodon.nl avatar

@simondh Ah, het antwoord is eenvoudig, basically "omdat ik die met die pas heb afgerekend" en hij gewoon een kloppende overzicht wil hebben.

Ik dacht dat het afgetrokken werd. Niet dus, wordt netjes als prive ding gezien en ook inkomstenbelasting over betaald.

@epso

hvangalen, to animals
@hvangalen@mastodon.nl avatar
hvangalen, to animals
@hvangalen@mastodon.nl avatar
  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • thenastyranch
  • magazineikmin
  • everett
  • InstantRegret
  • rosin
  • Youngstown
  • slotface
  • love
  • khanakhh
  • kavyap
  • tacticalgear
  • GTA5RPClips
  • DreamBathrooms
  • provamag3
  • modclub
  • mdbf
  • normalnudes
  • Durango
  • ethstaker
  • osvaldo12
  • cubers
  • ngwrru68w68
  • tester
  • anitta
  • cisconetworking
  • Leos
  • JUstTest
  • All magazines