HackerTrans
TopNewTrendsCommentsPastAskShowJobs

hmfrh

no profile record

comments

hmfrh
·há 2 anos·discuss
> Yes. The exporters can handle whatever meaningful address selection you can throw at them, including multiple disjoint ranges within the same section. So you can keep carving holes inside your selection until nothing remains of the original program.

Will this also work without painstakingly reversing things in the binary, say in the case of a giant game executable?

If possible, I would be very interested in a simple tutorial that takes an arbitrary Windows executable, delinks it and replaces a single function, without all the extra steps necessary to run it on the PS1.

It might even be preferable if it worked with MingW, since I'm on Linux as well.
hmfrh
·há 2 anos·discuss
> As long as you do not cut across a variable or a function, you can export pretty much however you want, you don't have to follow the original object file boundaries.

Would it be possible to export basically the entire program at once and then slice off individual functions one by one?

Do you have any guides/examples of the

> Decompilation projects, by splitting a program into multiple object files and reimplementing these Ship of Theseus-style

style project?
hmfrh
·há 2 anos·discuss
How much work is it to figure out which sections of the executable to export?

Would it be realistic to be able to export a modern-ish (2008-2015) Win32 game into objects and then compile/link it into a full executable again with less than a few hours work?
hmfrh
·há 3 anos·discuss
> So ultimately, the borrow checker doesn’t seem worth it if you actually think about the cognitive overhead and headaches it brings.

You quite literally also have to "borrow check" C/C++ in order to have a well formed program, just without any compiler assistance.
hmfrh
·há 3 anos·discuss
Surely the C++ surface area will also have increased significantly in the same span of time which means that Rust will still be ahead?
hmfrh
·há 4 anos·discuss
Other than Godbolt Rust also has cargo-show-asm[1] that directly shows the actual assembly.

[1]: https://crates.io/crates/cargo-show-asm
hmfrh
·há 4 anos·discuss
It appears to also be called the "abstract machine"[1].

C semantics do not work "directly on the hardware" but instead on an abstract machine that is then converted to the actual hardware.

It most often comes up when talking about undefined behavior and pointer behavior.

Some assorted reading, mostly in the context of Rust and C:

https://blog.regehr.org/archives/213

https://raphlinus.github.io/programming/rust/2018/08/17/unde...

https://www.ralfj.de/blog/2018/07/24/pointers-and-bytes.html

https://www.ralfj.de/blog/2017/06/06/MIR-semantics.html

[1]: https://stackoverflow.com/questions/53100198/what-is-the-pre...
hmfrh
·há 4 anos·discuss
> C having better support for pointers make it near to how the processor works, compared to other languages.

Java is almost entirely pointers to heap allocations, yet I don't think anyone would argue that Java is close to how the processor works.

I also don't think that the C virtual machine is all that close to how machines actually work any more.
hmfrh
·há 4 anos·discuss
> Do you want criminal prosecution for actual harm, or for potential harm?

Do you only want DUI to be illegal if it results in an accident?
hmfrh
·há 4 anos·discuss
> And how is these countries joining NATO benefiting the existing NATO members?

Stability in Europe. The west doesn't want refugees from whatever country Russia decided to invade this week to show up on their doorstep all the time, or the supply chain interruptions that happen when war constantly breaks out. You might remember that NATO arose almost immediately after World War 2 which had a rather negative effect on Europe and European influence in the world.

> Obviously, Russia has nothing more to lose given the sanctions, so, the only thing left is a direct NATO conforntation,

Russia has plenty more to lose. Namely every major European power and the US unloading all their armaments on Russian cities that are very close to the border.

> but it seems that the West is more afraid of such conflict than Putin, who believes that this is inevitable and that if you're faced with an inevitable flight, it's better to strike first.

This is an absolutely unrealistic take. Russia _can not_ win major combat against NATO in any shape or form. They couldn't do it with their made up propaganda army and they certainly can't do it with their actual army.
hmfrh
·há 4 anos·discuss
> It all looks rosy now, but remember just a few years ago when Turkey shot down a Russian jet on the Syrian border and almost led to NATO involvement?

Remember when Russia invaded Ukraine and it didn't lead to NATO involvement? We have direct evidence that a European country can be attacked without NATO immediately jumping in to help. If Russia "only" wanted the Eastern "wilderness" of Finland, do you think the other European powers would immediately send in their own troops?

There's a reason that the smaller European countries that border Russia haven't been attacked and absorbed yet, and that's because they're NATO members.

Being a NATO member clearly has more upsides than downsides.
hmfrh
·há 4 anos·discuss
You probably think that you do, but in reality you don't.

Large corporations have been proven to fix wages for tech workers[1]. There's literally no way that you could have any possible way of bargaining your way around that as a single person.

[1]: https://www.npr.org/sections/thetwo-way/2014/04/24/306592297...
hmfrh
·há 5 anos·discuss
> where is the bad news?

The bad news come when you reach the "Extinguish" phase. [1]

[1]: https://en.wikipedia.org/wiki/Embrace,_extend,_and_extinguis...
hmfrh
·há 5 anos·discuss
Introducing a new keyword means that all existing code that uses the new keyword as an identifier will break. That's why the `constexpr` keyword is deliberately weird.

It's also why they reuse keywords like `using`.
hmfrh
·há 5 anos·discuss
> She leaked a trove of internal research and communications showing the company was aware of the ills of its platforms, including the toxic risks of Instagram to some teenage girls' mental health and the prevalence of drug cartels and human traffickers on its apps.

Please read the article next time.
hmfrh
·há 5 anos·discuss
> What fascism used to be was ultra nationalistic, non democratic, centralised control of people's lives and the economy for the greater good of the state. And I means these to the most extreme you can possibly take these ideas, that's fascism.

That's not entirely true.

As Umberto Eco says[1]:

> Eco grew up under Mussolini’s fascist regime, which “was certainly a dictatorship, but it was not totally totalitarian, not because of its mildness but rather because of the philosophical weakness of its ideology. Contrary to common opinion, fascism in Italy had no special philosophy.” It did, however, have style, “a way of dressing—far more influential, with its black shirts, than Armani, Benetton, or Versace would ever be.”

And he identifies 14 typical features of fascism:

> 1. The cult of tradition. “One has only to look at the syllabus of every fascist movement to find the major traditionalist thinkers. The Nazi gnosis was nourished by traditionalist, syncretistic, occult elements.”

> 2. The rejection of modernism. “The Enlightenment, the Age of Reason, is seen as the beginning of modern depravity. In this sense Ur-Fascism can be defined as irrationalism.”

> 3. The cult of action for action’s sake. “Action being beautiful in itself, it must be taken before, or without, any previous reflection. Thinking is a form of emasculation.”

> 4. Disagreement is treason. “The critical spirit makes distinctions, and to distinguish is a sign of modernism. In modern culture the scientific community praises disagreement as a way to improve knowledge.”

> 5. Fear of difference. “The first appeal of a fascist or prematurely fascist movement is an appeal against the intruders. Thus Ur-Fascism is racist by definition.”

> 6. Appeal to social frustration. “One of the most typical features of the historical fascism was the appeal to a frustrated middle class, a class suffering from an economic crisis or feelings of political humiliation, and frightened by the pressure of lower social groups.”

> 7. The obsession with a plot. “Thus at the root of the Ur-Fascist psychology there is the obsession with a plot, possibly an international one. The followers must feel besieged.”

> 8. The enemy is both strong and weak. “By a continuous shifting of rhetorical focus, the enemies are at the same time too strong and too weak.”

> 9. Pacifism is trafficking with the enemy. “For Ur-Fascism there is no struggle for life but, rather, life is lived for struggle.”

> 10. Contempt for the weak. “Elitism is a typical aspect of any reactionary ideology.”

> 11. Everybody is educated to become a hero. “In Ur-Fascist ideology, heroism is the norm. This cult of heroism is strictly linked with the cult of death.”

> 12. Machismo and weaponry. “Machismo implies both disdain for women and intolerance and condemnation of nonstandard sexual habits, from chastity to homosexuality.”

> 13. Selective populism. “There is in our future a TV or Internet populism, in which the emotional response of a selected group of citizens can be presented and accepted as the Voice of the People.”

> 14. Ur-Fascism speaks Newspeak. “All the Nazi or Fascist schoolbooks made use of an impoverished vocabulary, and an elementary syntax, in order to limit the instruments for complex and critical reasoning.”

Many of which absolutely apply to the previous US presidency.

[1]: https://www.openculture.com/2016/11/umberto-eco-makes-a-list...
hmfrh
·há 5 anos·discuss
> Some days I can get a dozen robo calls, each with a different spoofed number.

I live in the EU and have literally never gotten a robo call in my life. It's a political problem, not a technical one.
hmfrh
·há 5 anos·discuss
> this is something that can change from person to person yes, but is it like that for you?

In my opinion it really depends on your background.

For example, Rust uses the `i32` type as the standard integer. If you come from a C/C++ background this is probably not that weird, you probably know how many bits there are in 4 bytes off hand, there's `int32_t` standard types and you probably have experienced not wanting an integer with a variable size that depends on the platform.

If however you come from Python, Javascript, or maybe even Java, this might range from a little weird to very weird. Python only has the `int` type, no unsigned types and you might not know how many bits make up a "standard" integer, or even exactly how bits, signedness and integer sizes fit together. Java doesn't have unsigned types and doesn't have issues with sizes depending on the exact platform, so they might not understand why you would want the amount of bits right there in the type name.

This is just for the standard integer type. If you consider how many design decisions are a direct result of working on low level, high correctness required C++ code, the "simplicity" could range from completely simple to very much not simple.
hmfrh
·há 5 anos·discuss
The Zero to Rust[1] series also has a fairly comprehensive look into these.

[1]: https://www.lpalmieri.com/posts/2020-09-27-zero-to-productio...