[HN Gopher] Click ___________________________________________________________________ Click Author : st_goliath Score : 174 points Date : 2021-03-19 21:27 UTC (1 hours ago) (HTM) web link (clickclickclick.click) (TXT) w3m dump (clickclickclick.click) | wlesieutre wrote: | Why does a webpage get to know how many CPU cores I have? | tomg wrote: | window.navigator.hardwareConcurrency | | [edit: well this is more of a 'how' than a 'why'] | Sephr wrote: | The answer to why: It helps with efficient allocation of | worker thread pools. | | I made a timing attack[1] as justification for adding this | API, and then presented this suggested API to each browser | vendor along with the timing attack. The result was that | every browser has adopted my suggestion. | | If this API was not present, ads could get this data in a | more resource-intensive manner anyways. | | 1. https://github.com/oftn-oswg/core-estimator | simias wrote: | Ahah, I like the "give up" approach to fighting browser | fingerprinting! "If ads can track us, we might as well make | it efficient". | fred123 wrote: | Reported by the browser but not always accurate. Used in | browser fingerprinting btw | moron4hire wrote: | So I can know how many worker threads to create before it's | just a waste of thread scheduling | seniorgarcia wrote: | https://developer.mozilla.org/en-US/docs/Web/API/NavigatorCo... | | There is no good answer to why, except to improve | fingerprinting. Which is most of what this site shows, the | amount of data a site, even open in the background, can use to | continuously fingerprint you. Or maybe I misjudge what this is | supposed to do. | franky47 wrote: | This is great. I tried to hack the progress by automating clicks, | using: let button = | document.getElementsByClassName('button')[0] | Array(100000).fill(undefined).forEach(() => button.click()) | | In response, I got the following log message: > | Such a smart subject. | skavi wrote: | Is that actually the best way to do ranges on JS? | halfmatthalfcat wrote: | Traditional for loops are probably the most common for ranges | but if you want a more functional approach you can use the | Array constructor or Array.prototype.from with its various | parameters. | franky47 wrote: | The functional approach also works better as a one-liner | when typed in the devtools console. | smoe wrote: | The other comment points out Array.from, which seems pretty | nifty. Have not seen it before. I would have used: | for(i of Array(1000).keys()) { doSomething() } | | or [...Array(1000)].forEach(() => | doSomething()) | johnfn wrote: | Well, _that 's_ an unconventional way to write a for loop. | Maybe the website is commending you on that :-) | notJim wrote: | This is your brain on javascript :) | | Guessing it's bc one-liners are easier to write than for | loops in the console. | halfmatthalfcat wrote: | Can save more bits by doing: | | Array.from({ length: 10000 }, button.click); | phogster wrote: | Never heard of a "from" loop before. | franky47 wrote: | Array.from lets you build an array from an iterable | source (often used in conjunction with `new Set` to | eliminate duplicates), or in this case, of a fixed | length. | [deleted] | franky47 wrote: | I did not know this variant, thanks. Having to fill the | array with anything (even `undefined`) to iterate on it | seemed such a weird concept (but then again, JS is weird). | makach wrote: | It responded correctly, it said: Robot, Exciting and then wrote | "subject has run script to click on the button ten times within | one second" whereafter "subject has clicked on the button a | thousand times" | | Maybe a contender to CookieClicker? 73% achievements atm | kag0 wrote: | Given the trick they use to prevent you from using the browser | back button, I was expecting it to comment "subject is trying to | escape!" | pmastela wrote: | Nifty. Now if only this was the required homepage on all major | browsers starting up for the first time then folks at home would | quickly become aware of just how well tracked they all are. | MarxOk wrote: | Sites like this often go down when they reach the HN first page. | I've naively deployed stuff on AWS free tier with no scaling or | anything that's handled thousands of concurrent requests out of | the box. Is the HN kiss of death that bad, or is it just that a | lot of people use weird/shared hosting providers? | jcpham2 wrote: | Surely not the first appearance? | codegeek wrote: | It depends on what type of site it is. A dynamic site with lot | of database calls/no caching would probably crash much quicker | than a static HTML page with same amount of traffic. HN easily | sends 100s of concurrent users if not many so it can crash a | shared hosted dynamic site with no caching. | geek_at wrote: | either badly coded website (heavily relying on some backend | without static files) or weak hosters but not sure I have a | blog that survived every single HN/reddit hug on a pretty weak | VPS. | | Blog written in PHP but without database interaction | alvarop wrote: | Reminds me of Samy's website. For a fun time, try to view the | page source: https://samy.pl/ | pkkim wrote: | Well there goes an hour. | runningmike wrote: | Security's worst nightmare! But brilliant creation from a | psychological point of view. Awareness Awareness Awareness... | gnicholas wrote: | > _subject disconnected from internet_ | | Not sure why I got this message, which is not true. | huskyr wrote: | This is a piece created by the Amsterdam-based Studio Moniker. | They have many more projects that play with the same ideas, see | here: https://studiomoniker.com/projects | tyingq wrote: | I did get a kick out of "https://donotdrawapenis.com/", which | has apparently collected 25,000 reasonable penis sketches. I | guess for ML training to keep penis drawings off of your | website? | navaati wrote: | "You visited about n sites before coming here" How the hell does | that work ? | tomg wrote: | window.history.length | | would be my guess. | navaati wrote: | Ugh, slightly creepy. Thanks for your answer ! | acwan93 wrote: | I can't find the website, but there's a site that specifically | tells you _everything_ it knows about you just by keeping the | page open. | | It tells you if it knows where your cursor is, what pages | you've been to, what your computer is, etc. | | It was intended to show that you, the user, give out a lot of | data without even realizing it. | zaczekadam wrote: | It's crazy how many things they predicted. Love it | TruthWillHurt wrote: | site is down. | | downdowndown.down | runningmike wrote: | The deathly HN kiss of lovelove.love ___________________________________________________________________ (page generated 2021-03-19 23:00 UTC)