Hacker News new | past | comments | ask | show | jobs | submit login
[flagged] Show HN: Detect Russian visitors to block them and protest the war in Ukraine (github.com/ob42)
55 points by FrenchDevRemote on Feb 26, 2022 | hide | past | favorite | 85 comments
It runs on the frontend in vanilla JS, it should work 9 times out 10.(false negatives near the border)

(Not that thoroughly tested but should be fine)




I see many Russians already enraged about the war, some even doing protests against it. The fact is that most feel powerless and afraid against an autocratic government, and I feel it’s very hard to tell them to retaliate when their lives are on stake. (Maybe your country hasn’t experienced this yet, but hearing anecdotes from my country’s past I understand it’s really hard to mobilize when the next day you can be kidnapped by the secret police and end up in a prison cell where you get tortured to death.) Resistance is necessary, but it’s far easier said than done.

I just don’t see a point treating ordinary Russians as “sinful” because of this event. If you’re enforcing standards like these on everyone, then I guess the entire US population is also responsible for all the the war crimes and atrocities the country has done for decades. And I don’t want to do that; even if the current elite controlling the US has done some of the most atrocious things in history, I don’t think the people living there “deserve” worse lives because they haven’t retaliated.


Then we shouldn't be okay with sanctions either, because effective sanctions are about damaging the economy so badly that the current regime feels the risk of instability. Sanctions rely on popular suffering to achieve this instability. Damage to the people is not a side effect but the core mechanism.

There's little difference between IP blocking and economic sanctions. They both damage the economy (and thus the people) by virtue of isolation.


I wholeheartedly agree, economic sanctions (including IP blocking) damage the populace far more than the regime. And it only increases resentment towards the powers that imposed the sanction.


> it’s very hard to tell them to retaliate when their lives are on stake

I think the general concept is that the pain to continue their lives must be bigger than the pain to try and dethrone the corrupt leader.

Not taking either side here, but I can see why it can work.


Honest question: has it ever worked? I know of many countries where it didn't work (e.g. Iran, Cuba, North Korea, Venezuela, Libya before the Western invasion, and even previous sanctions on Russia) but I can't think of one where it did.


Ironically enough, it worked in Ukraine. https://en.wikipedia.org/wiki/Euromaidan

Edit: maybe it wasn't squeezed out by an embargo, but it shows that people can overthrow a government.


> maybe it wasn't squeezed out by an embargo, but it shows that people can overthrow a government.

Absolutely, I don't question that. And economic issues can be a powerful force toward revolution.

But foreign sanctions always seem to strengthen the regime and provide a convenient excuse even for economic issues that aren't caused by the sanctions. Sanctions seem to make revolution far less likely, which isn't the desired outcome at all.


I guess I have to agree with you here, because I can't come up with a proper example.

But remark that economic sanctions do have its use by not pumping more money into aggressive nations.


It happened in the Soviet Union in 1991.


That's not what happened in the Soviet Union at all. The people didn't "dethrone the corrupt leader", in fact the people had very little to do with the events of 1991.

Instead, the leader of the Soviet Union (Gorbachev) attempted liberal reforms which provoked a coup attempt led by eight high level Soviet officials who were communist hard-liners. When the coup failed, the leaders of various Soviet Republics declared independence - including Boris Yeltsin, who was the leader of Russia within the Soviet Union before the coup (specifically, the Chairman of the Supreme Soviet of the Russian SFSR).

The whole thing was a power struggle between high ranking politicians.

And in addition, far from being evidence that sanctions can work, the Soviet example is evidence that authoritarian empires can collapse when they attempt to liberalize:

"The process of implementing perestroika created shortages, political, social, and economic tensions within the Soviet Union and is often blamed for the political ascent of nationalism and nationalist political parties in the constituent republics. Perestroika and its associated structural ailments have been cited as major catalysts leading to the dissolution of the Soviet Union."[1]

1: https://en.wikipedia.org/wiki/Perestroika


Well put indeed.

Some further points:

- Russia is not a regular democracy, it’s not like Putin has a democratic mandate for this war. Who can Russians vote for who is against the war?

- Oddly, “regular” Russians are allies of the West here. Ultimately Putin can only fail due to internal pressures. So ideal sanctions cripple Russian elites and put pressure on the regular citizens, without alienating them.

- Clearly, you can’t have your cake and eat it. If Russian revenues are affected through sanctions, regular Russians will suffer, as a byproduct. But blocking indiscriminately by IP is just a big middle finger for no good reason.


Well put. It is easy to forget that the actions of governments do not necessarily represent the will of the people.


I agree... The first hit on Duckduckgo when searching for "Discrimination":

"Discrimination is the act of making unjustified distinctions between people based on the groups, classes, or other categories to which they belong or are perceived to belong. "


There are at least two better things to do than outright blocking:

1. Show them the peace address to Russian people by the president of Ukraine, Zelenskyy.

2. Show them the photos of people taking shelter in Kyiv's and Kharkiv's underground metro stations. Russian media is banned from reporting anything but official information and official information lies that this is only a limited "de-nazification operation" in small eastern parts of Ukraine. These are extremely powerful photos, as they mirror the experience in Moscow under Nazi attack in WWII, which is as iconic to Russians as the photo of Iwo Jima flag rising or dead soldiers on Buna Beach are to Americans. There are other photos to show too, such as of burning churches in Sumy, which mirror the collective memory of burning churches under the Mongol invasion. Or that NY Times photo of a dead Russian soldier lying under a thin layer of fresh white snow next to a destroyed APC. Russia doesn't even admit any casualties yet and lies to its population every step of the way. Show them the truth!


You can run custom code and/or show a custom message, it's up to you.

I just made a simple tool to detect them, with a few basic default options, the rest is up to the owner of the website.


Thank you, it is really useful! Please don't take it as a personal criticism, it was not intended as such.


> as they mirror the experience in Moscow under Nazi attack in WWII,

Every war is the same. :)


No no, this is far worse. Major Ukrainian cities have always been considered a part of the Russian world. Russians bombing Kyiv sounds as insane as USAF bombing Philadelphia. There's no support for the war whatsover this time around, only horror and shame over what's happening, because it's touching those deep images from collective memory. The silhouette of an Orthodox church over the backdrop of a burning city[1] is like something straight out of countless movies about Nazi and Mongol invasions of Russia[2]. We see the Russian equivalents of "the smoldering wreck of USS Arizona at Pearl Harbor" coming from Ukraine and it cuts much deeper.

[1] https://twitter.com/aletweetsnews/status/1496976867064270858

[2] https://youtu.be/er3kGojjH5s?t=6021


Reported. This repository is clearly aimed at discriminating the whole nation of Russians who are a victim of dictatorship as much as Ukrainians are.

I know what I’m talking about: I’m Russian who has been protesting for 10 years. That resulted in nothing. If I keep protesting I’ll get in jail until I’m close to my pension. I don’t desire to sacrifice my life for nothing.

The fact that you think that Russians need a push to protest demonstrates that you’rea naive entitled person who was lucky enough to never face a dictatorship.

All Russians I know are against war. We can’t do shit and we feel hopeless as fuck.

I wish you all the best, but please cut this bullshit. Support Ukraine instead.


I'm very sorry for the damage that your leader is causing. I personally know Russians and they are very warm-hearthed.

But in the end the Russian military is funded by the Russian economy. It is of course true that the ones most impacted by a bad economy are ordinary people, but none the less its up to the rest of the world to decide if they want to deal with a country that uses it's funds in this way.


There are economic sanctions aimed at discriminating against the whole nation of Russia. The core mechanism of sanctions is to damage the people on the ground so much that the risk of regime instability becomes a story.


Not a good idea to harass people because you don't like what their government is doing.


Annoying them enough might push more people to protest. The softest option of the script is one alert() message once a day, that doesn't seems like harassment, the strictest option is to redirect you to a form on the russian government website, that's more debatable but that's up to you, you can also run custom code.

If you're annoyed/blocked while trying access a website you like because your government is oppressive you might have one more reason to protest.


I am a Russian thus I am biased, of course.

I see this as a means to divide further and to attain higher moral ground - "do THAT" in case of alert or "you are not welcome here until you SIGN THIS" in case of redirection.

For that to be a little bit more fair, I would like to see a detection of NOT Russian or Belorussian visitors with alerts and redirection to forms of their respective governments who did nothing to prevent a war.

Consider that a feature request. ;)


So what do our governments need to do to prevent a war? Go back to the Soviet years and let Russia claim all of it's former territory?


I think I should point out that you are talking about preventing ongoing war. It is just not possible to prevent harm that was and is being done.

I politely withdraw myself from answering your second question. It is too inflammatory.

I still think that it is possible for governments to learn - they are people, just like us, - and I think it is not only Russian government who can learn from this situation.

I should thank you - (non-)answering your questions made me think by standing in your shoes. It is interesting and important experience.


Thank you for your civil response, and my apologies for my rude response.

I will ask another more genuine question (it's a real question that I have). If Russia would have a more democratically elected leader (let's just say Navalny for the sake of argument). Would the ties between EU and Russia be more collaborative, or do you still think this would have ended with a war?

In other words, is NATO really out to destroy a democratic Russia (Soviet Union is already long gone)?


I think that boils down to whether concerns of Putin would be "more heard" if they were expressed by different person. From my point of view, some of these concerns were quite important for, let's say, viability of Russia as country with a pinch of independence.

I rephrase. If Russia wants some independence in its decisions from external influence(#), the concerns raised by Putin are valid whoever is the leader of Russia.

I think it is unfortunate if the acceptance of these concerns depends on the person expressing them. Moreso, I think it is unrealistic to expect that different person would express same concerns and get different results without exchange of some other important pieces.

In other words, it appears that NATO does not like Russia in its current form.

Of course I am glad to accept you apologies and, in turn, I would like to express mines. I know I can be excessively sarcastic in my tone and I would like to apologize for that.

(#) I came to think that politics are all about "whose influence we prefer this time of day". The right to choose is still important.


> Russia wants some independence in its decisions from external influence

Can you give an example of where Russia cannot take independent decisions?


What I said was conditional, "if Russia wants...". You cut my words out of this condition. I also should phrase it as "if Russia wants more independence..."

Right now I cannot provide you with concrete example.


But you talk about "concerns", so which concerns are that? That Nato would attack Russia?


One of these concerns was dual purpose rocket systems deployed next to Russian border. These systems could be refitted with nuclear heads.

That's one of things I remember, you may find other.


Dude, they lock you in Russia up if you protest too much. Russia is a full-blown dictatorship now with Internet censorship, state-operated propaganda and other bells'n'whistles.


They lock you up in a lot of places for the same reasons. Even in the US or in Europe you might get killed at a protest.

There is people protesting in Russia right now, no matter the risks, I don't see the harm in trying to increase their numbers.


Number of protesting people in Russia is a joke.


Vladimir Putin is an ex-KGB officer. The country has a system for monitoring all phone communications, and the major email providers are affiliated with the state.

Also, 100% of the media is spinning the "we're liberating Ukraine from the Nazis" take, and unless you spend very considerable effort doing your own research, you just won't find a single information source telling you otherwise.

And if you get anywhere close to organizing a protest with a non-trivial number of participants. They will figure out who's in charge, and will put you behind bars as a warning to others.

That, and people generally don't trust each other, don't trust the system, and are mostly busy trying to survive, find cheap food, and not get caught in a crossfire.


I suppose statistically speaking you might be right, though I find it hard to imagine what kind of person is going to risk beatings or years in prison or worse over a minor inconvenience like being unable to view their favourite website.

I think depending on the person this could go either way. Perhaps they feel spurned, isolated, or blamed personally, and respond with anger.


if only one site is using it yes that's nothing

if dozens of websites do the same that might push people to protest

internet is a huge part of our lives, most people use it for hours everyday, it can be more than a minor inconvenience


You might also think that the West is oppressing you and that your government's war is justified.


There was a poll done in December (YouGov) that showed that more than half of Russians thought NATO/The West was to blame for this situation.


And to visitors from North Korea you'd probably show 2 alerts, because they need a slighter stronger push to overcome their fear of being sent to labor camps. While you'll be watching news about their protests from a safe and comfy sofa.


Did you protest against your government back in 2015-2016, when half a thousand of your men, women and children got shot, blown up or smeared on the sidewalks in retaliation for two decades of your government's involvement in destabilizing countries, hundreds of thousand people dead and millions more displaced?

You didn't? Oh, was it not justified to hold your civilian population accountable for the actions of your democratically elected and re-elected leaders? Or did you just not get annoyed enough?


Nice I am gonna do the same to Canadians because of their government mandates, give Trudeau a lesson

Instead of a flag l can use a truck emoji


is Canada invading a neighboring country?


The point is

Russian gov does something you disagree, annoy Russians

Canadian gov does something you disagree, annoy Canadians

But yes they also took part in Syria, Iraq and Libya's invasion


That's not the situation

The Russian gov is murdering people as we speak.


Canada arms sales to Saudi Arabia are also killing Yemenis as we speak, indirectly and directly

https://www.theglobeandmail.com/politics/article-un-experts-...


Unrest of a few oligarch is a problem. Unrest of the majority is an existential threat. Nowadays I support the second one :(


Some harass people, the other kill them. Which one is not a good idea, tell me?


* if you don't like that their government is starting a war and murderring inocent people.

it might be the only way substantial contrarian views can reach them, since major news media is strongly censored.

I would make it strongly worded and optional, click here to continue if you don't support Putin's war.


btw there is options in the script to make it optional and with custom messages, or run custom code

as I don't speak russian I only put a very basic default message


Everyone can do whatever they want stop scolding people for every little thing sometimes people need the feeling of action especially when you are detached and helpless to current events.


How come no one ever does this when it's America killing innocent civilians? I don't support the war but I'm somewhat amazed at the reaction people are having to it. I don't think the plight of those in the middle east ever reverberated like this


Because of propaganda. Time to (re)read Manufacturing Consent.


I was too young when most American wars started but I would have done the same

if anything I resent more the US gov than the Russian gov, it's just that it's happening right now


A 5 seconds search shows that the US were bombing Syria as close as one year ago.


it's a very different and more complex situation. they did bad and good things at the same time in that area.(when I say good I mean trying to fix the mess they partly created)

Russia is just straight up invading a neighboring country. there is no good in any of their current actions.

I was mostly talking about what happened just after 9/11.


The situation in Ukraine might be more complex than you think.


You mean, the jewish president is a real Nazi ? Am I missing something ?


how?


A few keywords to search for: Russians in Ukraine, Maidan, Minsk protocol, neonazis in Ukraine, NATO and Ukraine.


it can be summarized as Putin want more power and access to a warm sea


Not so long ago you were claiming that the US hadn't attacked anyone in your lifetime. Confronted to the evidence that it was a false statement you start making a difference between the "good wars" and "bad wars". In one case the situation is "complex", in the other it can be summarized in one sentence. Don't you see the double standard here? How about "Russia takes action to protect its people against Western imperialism and fight nazism"? Of course that would be an equally oversimplified summary of the situation.


"Not so long ago you were claiming that the US hadn't attacked anyone in your lifetime."

the English curriculum in Russian schools must be really awful because I never said that


More tool ideas for you:

- detect code contributed by Russian developers and automatically delete it from a Git repo of choice,

- automatically unfriend all Russians or people of Russian descent (configurable via --depth option) on social networks,

- automatically downvote books by Isaac Asimov, Chuck Palahniuk, movies by Woody Allen (Russian mother), Michael Bay (Russian grandfather), or starring Daniel Craig (007), Timothée Chalamet (Dune), Leonardo DiCaprio, Jake Gyllenhaal, Natalie Portman, Milla Jovovich of course, all the Kravitzes and many many more - they're all of cursed Russian stock!


The translation is correct, but it says “[a] protest against the war”. If you want to imply a call to protest, it should be “протестуйте против войны».


fixed it, thanks!


Please don't do this, if anything you're helping with the propaganda that Ukraine is a "NATO puppet state".


Well, any help they will get can help this propaganda, it's not a reason not to help.


Why not block only (rus) gov IPs for all services you're running?


Hmm. Trying to think of an instance when history reflected kindly on a li’l lite persecution of an entire population. Someone help me out?


Slightly off Topic: How to geofence ssh? I don't expect where to login from Australia, so I could restrict it


Interesting, making hatred even more, nice job indeed. But one question tho, if Ukraine story is hot topic, then why American sending troops around the world, like Afghanistan, Syria, Iraq, etc... Why no one standed against America, answer is... Bingo, they control the media

How about china, muslim uyghurians story, why nothing happened, because silicon valley companies are making profit out of it

What I want to say is, as long as you are superpower, human rights is just straight joke (I don't support anyone)


It wouldn't make any sense for China because of the great firewall and the fact that the government wants everything to be hosted in china. it would be completely useless.

The next time the US invades Mexico I'll fork it and change two variables in the script.


seems about as effective as holding up a peace placard to an armed soldier. good job stopping an invasion honey!! you get a gold star for doing your part! yay!


Showing support for Ukraine is good, but blocking Russian visitors can only help Putin make ordinary Russians - which jad no say in his war policies - feel under siege, which is exactly what Putin wants.


It doesn’t matter it’s a dictatorship they are powerless.


How many dictators fell over the last few centuries?

dozens?maybe hundreds?

Putin will fall at some point, just like everyone before him, he's not a god, it's not a matter of if it's a matter of when.


Stalin lived a long life and died the tyrant of Russia, same with Lenin, and Peter the Great


Stalin might have lived longer if people weren’t too terrified to check on him after a night of drinking.


Yeah, but stop pretending that the Russian people have any sort of influence at the moment.


I believe (hope) they will have influence at some point, but it’s definitely not going to be because someone made a Javascript plugin on Github to block Russians.


Of corse they do. They do not operate in vacuum. If 10k Russian soldiers die and their mothers would go to street, what would Putin do? Beat them up? They may not have a man power to arrest all of them and place to put. This may cause some people in places like Dagestan to revolt. Workers in a tank factories could go to strike.

Putin and buddies to have to calculate that risk. It may cause a cease fire.


Yes, punish the civillians of russia for the decisions of the global oilgarchs. I love the foaming-at-the-mouth war effort here.

Lest we forget the true words of Hermann Goering,

    "voice or no voice, the people can always be brought to the bidding of
    the leaders. That is easy. All you have to do is tell them they are
    being attacked and denounce the pacifists for lack of patriotism and
    exposing the country to danger. It works the same way in any country."


Jesus quotes Göring in English in relation to a Russian war. Globalization prevails.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: