Better HN
topnewbestaskshowjobs
Log inSign up

CyberShadow

2,127 karma · joined Jun 21, 2009 (17y ago) · 465 submissions

I am Vladimir Panteleev, a D hacker from Moldova, Eastern Europe.

https://github.com/CyberShadow

[ my public key: https://keybase.io/cybershadow; my proof: https://keybase.io/cybershadow/sigs/iQOqJAZGCVN0DykK2PLwcTGU247dIo3aZnm6s6VOgjk ]

Submissions

comment 3y ago · link · parent

FWIW, if you use matrix-docker-ansible-deploy, enabling the Sliding Sync proxy involves just adding one line to your configuration (for the most common setup).

https://github.com/spantaleev/matrix-docker-ansible-deploy/b...

comment 3y ago · link · parent

Um, how exactly do you mean that? The pre-GitHub equivalent would be giving people commit access to the CVS/Subversion repository. This generally did not happen lightly either in most projects.

comment 3y ago · link · parent

I use NameSilo but am 50/50 on it. Their control panel does not send a "Content-Type" header, which is effectively mandatory, and the support team flat out could not understand what I was talking to them when I was trying to point it out to them. It "worked" in Chrome and Firefox without add-ons and that's as far as their concern ended.

comment 3y ago · link · parent

The settings page has this text:

> including where local laws restrict using pronouns other than those assigned at birth.

Where do such laws exist?

35.

Add pronouns to your GitHub profile(github.blog ↗)

5 points · by CyberShadow · 3y ago · 3 comments

comment 4y ago · link · parent

One rather un-obvious property of most mechanical keyboard switches made today is that the tactile feedback actually does not match the actuation point - meaning, the point at which the switch "clicks" is not the same point where the PC starts registering the keypress. In fact, in e.g. Cherry MX switches, these two are handled by separate mechanisms! The only switch type where actuation == tactile feedback that I know of is buckling-spring, as in the IBM model M.

This realization was a big moment of disillusionment in (most) mechanical keyboards for me :)

comment 4y ago · link · parent

A slightly-relevant project: https://github.com/CyberShadow/ripfs

Also, could this be the same pisto of RubberWorm fame?

comment 4y ago · link · parent

If I give you my phone number, and you have True Caller installed and save my number to your contacts, I unknowingly and unconsensually also give my phone number to True Caller and essentially the entire world.

comment 4y ago · link · parent

Indeed. You may also want to buy a bunch of (preferably pre-activated) SIM cards, as registering such accounts will require a phone number, and they limit the number of accounts that can be created with one phone number.

comment 4y ago · link · parent

Thank you for posting that link. The last time I checked, they were asking to install their app and then unlist yourself from there.

comment 4y ago · link · parent

Mysterious person in a hat and trench coat.

Perfect.

comment 4y ago · link · parent

I tried doing something similar for another game (fully explore and dump the dialogue tree of VA-11 Hall-A), and also encountered the state explosion problem. What helped was a data structure which allows storing very large sets of states, storing all possible outcomes of a program's execution efficiently (or at least more efficiently than naively). It exploits that any particular step in a program's execution reads and writes only a limited set of variables, which means that we can execute that step once only for each set of values the read variables may have, passing through all possibilities for the values of the remaining variables in one go. Perhaps it could be useful here as well.

https://steamcommunity.com/sharedfiles/filedetails/?id=22411...

comment 4y ago · link · parent

> In a case like Worms where there are concurrent actions and random reveal choices inside each turn... If some deterministic state and random number is created for each player at the start of the turn, then their inputs can be reproducibly mapped to the results of all the random choices. In that case you can just upload the inputs and let the server work out what happened based on the hash the player was given (i.e., let the server replay each player's inputs against that hash and figure out the result).

No, this is the worst of the two cases: it allows predicting all outcomes at the start of the turn AND allows manipulating the outcome. So, in a territory control scheme like Team17, you can choose whether to pick up that crate now, or wait a turn or two until picking it up will result in a better outcome.

> But the server is not another player. It's not a player at all. It's the arbiter of truth.

No, that's not how peer-to-peer games work. In the current implementation, it is the "arbiter of truth" because it's the "server" in the TCP/IP sense, but it is still run and controlled by a player, and should not have any intrinsic advantage.

> At some point games will just accept this and allow the player with too slow of a connection to be disadvantaged.

Maybe games with a centralized networking model. We deliberately avoided doing anything in this direction for Worms Armageddon because it puts a death clock on the game and the community - see all games which are no longer playable because the developer/publisher decided that keeping the servers online was no longer profitable.

> To the extent that a server should tolerate slow connections, it is a handicap given by the game to players with slow connections.

In the hypothetical secure scheme I described above, ALL players are affected, not just the slowest one.

comment 4y ago · link · parent

This extension is closed-source and its code is obfuscated. It also phones home according to the Firefox permissions. I'm not sure I would trust it.

Edit: more information in the HN announcement: https://news.ycombinator.com/item?id=26590720

comment 4y ago · link · parent

> They connect by default with aptX (A2DP mode) but using KDE tray icon, I can easily change it to full-duplex headset mode with mSBC.

As of wireplumber 0.4.8, they will now automatically switch to the headset profile when an application begins recording audio! It's now almost seamless (though I do still need to manually select the audio device every time in Firefox).

comment 4y ago · link · parent

You will generally want the outcome to be actually verifiable to everyone, not just the immediate participants.

comment 4y ago · link · parent

> I'm not sure I understand why there'd ever need to be an instant result (sans network latency) in a turn-based game. If the player has a visual indication that the server is waiting for their command, then any jumpy movement on the part of other players is strictly down to their own bad connection as long as the server is running well.

Although the Worms games are turn-based, gameplay typically involves performing a lot of actions within one turn. Walking, jumping, using utilities (which don't end your turn), and finally firing a weapon. Many of these actions can trigger an event with a random outcome, which should ideally be unpredictable and un-manipulatable, such as which weapon will be found in a weapon crate, or how long the fuse of a mine with a random fuse will be.

In a peer-to-peer game, the server is just another player, and should not be considered intrinsically more trustworthy. Ignoring latency, it's possible to implement a scheme of securely generating random data, in which everyone produces a verifiable hash (commitment) of a random number, and after everyone announced their hash everyone announces their random number, which is then XORed together to produce the outcome (see e.g. Keybase's "Cryptographic coin flipping"). The problem with this approach is that the latency to obtain the result becomes the roundtrip to the player with the slowest connection and back.

comment 4y ago · link · parent

The second-generation Worms games (2, Armageddon, WWP) use the same approach (here called "Deterministic action propagation method"). It was implemented by Karl Morton, and we also use it for replay files (which is why the game logic is meticulously versioned).

The solution we used for managing secret state, when the state is from a random source, is to delay generating the secret information for as long as possible (so, e.g., if a card is drawn, the drawn card is decided at that moment, as opposed to pre-shuffling the deck at the start of the game). We experimented with some designs in which the secret is revealed only to the player who owns it, and the rest only see a verifiable hash of the secret until the player performs an action which reveals the secret; however, it doesn't solve the general problem that any time the game must immediately (without network latency) make a random choice, the design must compromise between either allowing a hacked client to predict the result (when the RNG output is stable) or manipulate it (when the RNG output changes very often, e.g. every frame).

Sadly, the newer games went for a simpler synchronization algorithm, in which if a discrepancy is detected, the entire state is simply copied over from one player's game to another. This does allow blatant cheating; I'm guessing it was a concession due to the new engine lacking in robustness or portability.

comment 4y ago · link · parent

May I suggest placing it in a <details> tag. I'm finding it difficult to pay attention to anything on the page when there's a constantly blinking animation on it.

> It helps people that don't know that you can watch to subscribe for updates.

How would one fairly decide which project READMEs should have such an animation, and which shouldn't? It certainly calls a lot of attention to itself.

comment 4y ago · link · parent

What's with the "star and watch" animated GIF in the README? Should I start putting one in all my repositories? Should everyone be doing that as well?

comment 4y ago · link · parent

Hey, you forgot to put this in the title: "written in Rust" :-)

This looks nice, though I looked through my command history of "watch" and couldn't find any use cases where hwatch would be more useful. Am I using it wrong?

comment 4y ago · link · parent

What is "LTD"?

comment 4y ago · link · parent

Have a look at Linux Deploy, it is essentially an installation wizard and launcher.

I no longer use it, and instead use Magisk startup scripts to start the Linux userspace, but it remains useful as an installer.

comment 4y ago · link · parent

I found it to be true in most cases, and when it is not... well, we can vote with our wallet.

Case in point: I had never heard about Onyx. Coincidence or causation?

comment 4y ago · link · parent

Since Android uses the Linux kernel, if you have full access to the device, you can already generally sideload a distribution of your choice onto the filesystem. The Linux userspace can run and coexist alongside the Android userspace. Though some applications may require kernel features which are not enabled in typical Android kernels, GPL forces manufacturers to release the kernel source code, which makes it fairly easy to enable more features and use that kernel.

The advantage of this approach over running Linux in a sandbox / VM is that you can administer your Android device from the Linux side, which means that you can use your existing backup strategy or other automation tools. With a USB/bluetooth keyboard, it can also work as a small PC in your pocket.

comment 4y ago · link · parent

That's a cool find.

On a practical note, at the top level or in the middle of progn-like constructs, you can do "block comments" with just:

'( ... )

I.e., quote the form to prevent evaluating it.

comment 4y ago · link · parent

(2017)

More impressive: manipulating strings at compile-time.

Even more impressive: using string manipulation at compile-time to build valid D code, then use string mixins to inject it into the current program, passing it on to the compiler to be compiled as part of the program being built. This is done by std.regex to compile regular expressions to native code during compilation.

Even further impressive: using a string import to read a DSL from disk, transpiling it into D code, and passing it on to the compiler. This is used by Vibe.d to compile HTML templates to native code.

Granted, all this is fairly old news, and a few other languages have since caught up.

comment 4y ago · link · parent

Have you tried GitHub Discussions? They even have a Q&A mode for your own mini StackOverflow.
12345
16