Despite privacy concerns, CISA bill poised for passage - <AUTHOR> http://america.aljazeera.com/articles/2015/10/26/despite-concerns-cybersecurity-bill-heads-to-vote.html <comment><USER2> There's an AMA on reddit right now with the EFF, Access, Fight for the Future, FFTF, and Demand Progress about this.

[https://www.reddit.com/r/IAmA/comments/3qban2/oh_look_its_th...](https://www.reddit.com/r/IAmA/comments/3qban2/oh_look_its_that_cisa_surveillance_bill_again/)

Looks like it just started a few minutes ago, so no idea if it'll be useful, or not.

<comment><USER3> I'm never super happy with EFF's advocacy (I think they do good and important legal and technical work but I'm almost always unhappy with how they represent policy to the public).

I've been _uniformly_ discouraged by FFTF's advocacy, which I find goes way past "misleading" into "straight up dishonest", such as their recent piece that strongly suggested Facebook supported CISA (a fact not in evidence, for whatever that's worth) because doing so would immunize them from privacy suits for user data so long as they dumped all that user data to the USG. No reading of CISA gets you to that.

Example from today's AMA is FFTF's claim that CISA "exempts itself from FOIA", making it impossible to challenge in court: they're referring to Sec 4 (d) (4) (b), which exempts from FOIA _individual shared indicators_ , which of course must be the case, because indicators are things like compromised account names and passwords. That's all the law exempts from disclosure.

<comment><USER4> It is uncontroversial to state that corporations and special interest groups frequently lobby in public for a position and in private against a position. Frequently you know this only through un-attributable information passed to you.

Advocacy organizations are not journalists. They don't need to cite their sourcing before making claims they believe are true. The purpose of calling out Facebook is an attempt force them to align their public and private positions if they differ.

As usual, Marcy does excellent analysis about what information NSA will be able to collect, analyze and disseminate under CISA.[1]

[1] [https://www.emptywheel.net/2015/10/26/two-intended- consequen...](https://www.emptywheel.net/2015/10/26/two-intended-consequences- cisa-supporters-will-be-responsible-for/)

<comment><USER3> This is a blog post that makes two very broad claims:

1\. That Chrysler can exploit CISA to avoid liability for vulnerabilities in their cars simply by sharing the flaws with the USG as an "indicator".

2\. That the USG can use CISA to collude with private companies to avoid warrant requirements and spy on their customers.

Both of these points are, I think, false. I've linked upthread to the text of the bill and provided a summary. In particular, I don't think the "Chrysler reading" of the bill finds any support at all in the text; Chrysler is immunized from suits _stemming from their own sharing_ , and even in the sharing, they are explicitly on the hook for negligence and misconduct.

If it's helpful, here's the entire limitation of liability in CISA. Notice: companies are exempt from liability for _monitoring_ , _sharing_ , and _receipt_ of indicators. They aren't exempt from liability for having vulnerabilities in the first place!

        6.Protection from liability

        (a) Monitoring of information systems

        No cause of action shall lie or be maintained in any court against
        any private entity, and such action shall be promptly dismissed,
        for the monitoring of information systems and information under
        section 4(a) that is conducted in accordance with this Act.

        (b) Sharing or receipt of cyber threat
        indicators

        No cause of action shall lie or be maintained in any court against
        any entity, and such action shall be promptly dismissed, for the
        sharing or receipt of cyber threat indicators or defensive
        measures under section 4(c) if—

        (1) such sharing or receipt is conducted in accordance with this
        Act; and

        (2) in a case in which a cyber threat indicator or defensive
        measure is shared with the Federal Government, the cyber threat
        indicator or defensive measure is shared in a manner that is
        consistent with section 5(c)(1)(B) and the sharing or receipt, as
        the case may be, occurs after the earlier of—

        (A) the date on which the interim policies and procedures are
        submitted to Congress under section 5(a)(1); or

        (B) the date that is 60 days after the date of the enactment of
        this Act.

        (c) Construction

        Nothing in this section shall be
        construed—

        (1)to require dismissal of a cause of action against an entity
        that has engaged in gross negligence or willful misconduct in the
        course of conducting activities authorized by this Act; or

        (2)to undermine or limit the availability of otherwise applicable
        common law or statutory defenses.

<comment><USER5> I'm not sure why you were downvoted for a reasonable post citing original sources (I upvoted you to try to correct that).

I expect I will disagree with you about the desirability of CISA, just as we disagreed years ago about CISPA, but enjoy your posts on the topic nevertheless. They make thoughtful and reasonable points. Even if you end up on the wrong side. :)

<comment><USER3> Just to be clear: CISA is bad. I oppose it.

<comment><USER6> How many comments have you made expressing your opposition, versus painting groups fighting CISA in a negative light?

<comment><USER3> I'm not "painting" anyone. People say things that are misleading, wrong, or outright dishonest. I point them out. I don't feel any need to justify that to you.

<comment><USER6> Well, wouldn't it be more productive to write your own blog post(s) on why CISA should be opposed?

<comment><USER3> It would be about as productive as you writing a blog post about how much you disagree with my comments.

<comment><USER6> CISA impacts more people, to say the least

</comment></comment></comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER7> I can't believe the number of times this bill has been voted down, only to come back up for a vote again under a different bill or different name.

It is like they keep submitting bills until it gets passed. This not only is a waste of time, it seems to be how the lobbyists get their bills passed. Eventually one will get passed and then our privacy will no longer exist. If you want our data, get a judge to order a search warrant. Otherwise it is Unconstitutional.

<comment><USER8> >If you want our data, get a judge to order a search warrant. Otherwise it is Unconstitutional.

This is my position and nothing will move me from it because it is the principled position. Moreover, the advocates of mass surveillance fail to realize that even if their motives are as pure as the driven snow nevertheless a mass surveillance system will attract sociopaths and psychopaths who survive by preying on other human beings instead of creating value and trade. This is exactly why we have a Constitution to limit the powers of government.

<comment><USER7> I fear a Police State where it is basically an 1984 type of society. Instead of TV sets watching us, it is our smart phones. The only thing protecting us from the Thought Police is the fact that our smart phones are encrypted so that we can have privacy. Take away that encryption and let the Police or anyone else have access to anyone's smart phone and there is no privacy and you can be arrested for stuff you didn't do but might because some machine learning algorithm says you might commit a crime. Sort of like the Minority Report TV show were they stopped using precogs and went to a Hawkeye program that uses ML to tell if someone is going to do a crime and has access to everything in the public to tell.

</comment></comment></comment><comment><USER9> One of the things that concerns me about this debacle is that ongoing CISA controversy will eliminate the possibility of legislative support for information sharing for good. I appreciate that there are privacy concerns in CISA, however, it is very important to the security field that sharing of intelligence indicators become more plainly safe from a legal perspective.

'Indicators' usually consist of information about external actors and organizations that are relevant to intrusion detection, for example, the most common types of indicators are domains used for C&C and hashes of malicious files. It is difficult to construe a privacy violation from these types of indicators. There are concerns about certain providers who may have indicators relevant to their users - for example, some providers might share the names of otherwise legitimate user accounts which have been compromised as these are often used to send spam that ought to be blocked. However, in general, cyber intel indicators do not involve sensitive information about users.

Right now a great deal of organizations are not participating in public or private threat information sharing because of concerns over liability and compliance, and this significantly impedes defense by letting threat actors get away with infrastructure and tool reuse that ideally should reveal them. These acts originated as an attempt to correct that. It looks alarmingly like many advocacy organizations want to keep it this way for good.

I don't want to be painted as anti-privacy and I would say that I'm not, but the principal goal of this legislation is not to send your data to the NSA, it's to help me do my job. I hope that the internet community will have the foresight to try to resolve the specific problems with current legislation, and not to entirely prevent information sharing.

<comment><USER10> There is already a pretty large threat intelligence information sharing effort in place through the ISAC system established by DHS: [http://www.isaccouncil.org](http://www.isaccouncil.org)

These have seen widespread adoption by medium and large sized companies, and are doing good work. Or at least the one I participate in is; I can't speak for the other ISACs.

They have policies that facilitate information sharing without privacy or liability issues.

There are definitely still a very large portion of organizations that are not a member of any ISAC or similar information sharing group, though. I don't know how much CISA may help with that.

<comment><USER9> You may find it meaningful that, in my interactions with several people involved in operating ISACs, I have heard nothing but support for CISA. One high-up individual in a well-known ISAC expressed a great deal of frustration and said that opposition to CISA came only from people who had no idea what it was indicators were. I don't think that it's quite that simple, but there's certainly an element of that.

Much of the benefit of CISA is specifically in the area of information sharing with the gov't, which has various initiatives like NCCIC that are falling flat in a lot of ways. Of course the ISACs would like to be involved in this. CISA is also seen as a way to get a lot more organizations to contribute to ISACs, as well.

</comment></comment></comment><comment><USER11> Setting aside any hatred for the government and mistrust, how does Company A share information with Company B (or the FBI) about how a hacker got into their networks?

Is the concern that Google is going to hand over your browser history under the guise of CISA?

<comment><USER3> The law doesn't define how information is to be shared; it merely makes it lawful for the sharing to happen, so long as it meets the conditions in the statute.

This is pretty typical for bills in US Federal Law: Congress enacts a relatively broad statute that establishes principles relied upon in a later "rulemaking" process; the statute will delegate to specific agencies the privilege of making those rules.

<comment><USER11> If this law isn't enacted, then it will continue to be illegal for Company A to share breach details with the government, or with each other.

Is this necessary to slow down the rate and severity of breaches? If so, what should this law look like?

<comment><USER3> I don't think the harm outweighs the limited good in this situation. I'm negative on CISA. I was neutral on CISPA, which didn't have the law enforcement investigative enhancements CISA has.

But I still don't think it's a big deal either way. Like, don't donate money to prevent it from passing if this is the only donation you can make this year.

</comment></comment></comment></comment><comment><USER3> The actual text of CISA:

[https://www.govtrack.us/congress/bills/114/s754/text](https://www.govtrack.us/congress/bills/114/s754/text)

There are no amendments to CISA that I can find (CISPA collected quite a few amendments, some of which were very relevant to HN, before the bill eventually died).

I read CISA so you don't have to! (You still should). Here's a summary:

There are three particularly important defined concepts:

<<Sec. 2 (5) (A) "Threats">>, which means "unauthorized activity" that might plausibly compromise confidentiality, integrity, or availability, but that isn't either protected speech or a mere ToS violation.

<<Sec 2 (6) "Indicators">>, the most important concept in the bill, which is, roughly: logs of recon activity, exploit techniques, vulnerability data, account hijack techniques (I think this bill actually tries to capture the notion of an XSS), bot C&Cs, damage reports on attacks, and anything else related to security and not already prohibited by law.

<<Sec 2 (7) "Defensive measures">>, roughly, things that stop or monitor attacks.

"Defensive measures" is a confusing concept in the bill. For awhile, it was thought that CISA would authorize something akin to hack-back privilege for private entities; it does not. Meanwhile, defensive measures are probably _already_ lawfully shareable. Anyways, the bill allows you to share both indicators and defenses.

The bill allows the USG to share indicators and defensive measures with private entities, and vice versa.

So then:

Section 3 of the bill authorizes the USG to share stuff with private entities. This isn't the part of the bill that concerns people (we all probably want _more_ sharing from USG to private entities; for instance, that's what we're saying every time we demand NSA fork over its zero-days).

Section 4 authorizes private entities to share with the USG. Here's what it allows:

(a) You can monitor your own systems, or those of people who give you written authorization, for any security purpose, notwithstanding any previous limitation on monitoring. Even if ECPA or student records law says you shouldn't monitor, if you're doing it to deal with security threats, you're now allowed to.

(b) You can run your own defensive measures, or defensive measures on people who give you written authorization. Ok then.

(c) You can share indicators and defenses with the USG, and receive them from the USG so long as you comply with their sharing restrictions.

(d) You have to keep the data secure, you can't share it willy-nilly, and before _you_ share anything, you have to (1) review it for PII and (2) anonymize any PII you find.

Sec 4 (d) (4) has problematic language that allows, say, Facebook to provide written authorization to the USG to prosecute based on shared indicators; in theory, they can do this even if the prosecution they're going to launch isn't related to a computer crime, but just happens to be illuminated by the indicator Facebook shared. (But remember: Facebook can't share under CISA unless they have a bona fide cybersecurity purpose for doing so).

Section 5 has a bunch of rulemaking authority in it, but buried in it is Sec 5 (d) (5) (a), which gives all the purposes FedGov is allowed to use indicators for:

* any security purpose * attributing threats * determining whether threats are foreign * preventing immediate disaster/harm (iv) * stopping child sex trafficking (v) * stopping major felonies, espionage, trade secret theft (vi)

(iv), (v), and (vi) are major problems; these aren't cybersecurity purposes at all, but rather a sort of "these crimes are so bad that we're allowed to repurpose indicators to deal with them", which, maybe fair enough (except for trade secret theft), but still, not OK that new investigative capabilities are buried in the middle of a cybersecurity bill.

And that's it.

<comment><USER12> I could be missing a further limitation, but doesn't Section 4(a) _de facto_ amount to a repeal of all other laws that limit monitoring? Yes, the exception is limited to monitoring for a "security purpose", but a pretty broad range of things can be justified as a "security purpose". I'm also skeptical that courts will seriously second-guess companies' representations on that point.

<comment><USER3> Yep, I called that section out for that reason. I'm not particularly worried about it (I think this part of CISA mostly just clarifies something that was already pretty much settled).

Companies aren't allowed to just make up "security purpose", though; under CISA, they have to be monitoring for threats as construed in CISA, which means, for instance, they can't find exemption for liability for monitoring for mere ToS violations.

<comment><USER13> Couldn't one collect logs of all things, under the auspices of collecting logs that (may) contain "recon activity" and "exploits"? It seems on a surface reading that one could collect all those under the umbrella of collecting Indicators, and then also use it also for things like selling-to-advertisers or other business-related things.

Of course, our terms of use on most sites already say they can collect + monetize such things, so maybe this is moot.

<comment><USER3> I'm not sure I see the part of CISA that allows you to sell your logs to advertisers. I do see lots of places in the bill that allow sharing to other private entities or to the USG for cybersecurity purposes.

<comment><USER6> Sounds like a loophole.

<comment><USER3> What specific part of the bill reads like a loophole that would allow Facebook to sell its security logs to advertisers?

<comment><USER6> I was just responding to what you'd said above:

> I do see lots of places in the bill that allow sharing to other private > entities or to the USG for cybersecurity purposes.

<comment><USER3> "For cybersecurity purposes".

It's a short bill. Read it again! These terms are defined, reasonably well.

</comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER14> They write these articles as if the people of the United States have any say in the matter...

<comment><USER15> it all starts with people not voting for who they are told to vote for. I am quite sure that the majority here will vote for the candidate at the top of the party that the donor class/establishment has decided wins. Just like the Republican party establishment who fights against the Tea Party (for which the media and establishment convinced many voters of both sides to mock them) the Democratic party may be having its own similar moment with Sanders. Yet it doesn't matter if you still vote for whom you are given regardless of your personal choice.

Politics in the US cannot change until people simply say no. That means at least voting for someone not from the big two or voting against your own party to show them the lesson they need.

After all, how can your vote be wasted doing so when so many are convinced their vote already doesn't matter?

</comment></comment><comment><USER16> ₋ Four Letter Acronyms do not a policy make

₋ The net is a-central and not dependent on a single facist org to run it

₋ Pirate utopias will crop up to subvert any such control mechanisms.

⸗ 4 letter acronyms by virtue of being over⁻arching make the net stronger by way of streisand effect

<comment><USER17> It's somewhat ironic to think how "pirate" once meant someone who takes everything you have and gives nothing back, but today a pirate is a very generous individual who contributes their time and money, not to mention risking personal safety, in order to give you free access to contemporary culture.

</comment></comment><comment><USER18> So just hack this one government system and get everyone's vulnerabilities. Thanks for making it easy. Maybe someone will work as a contractor and post them all somewhere.

</comment><comment><USER19> Once again we can thank Dianne Feinstein for this. How did she get re-elected again? Was it gerrymandering or did her NSA buddies, which she keeps propping up, hack the poorly secured voting machines?

<comment><USER20> Feinstein is a senator. How could gerrymandering have anything to do with her election?

<comment><USER21> Have you seen the shape of California? I mean, it's implausible at best. :-)

But seriously, it's kind of fun to imagine what life would be like if U.S. states were shaped like House districts. Maryland is probably the closest, geometrically.

<comment><USER22> _Have you seen the shape of California?_

Did you know that Reno has been gerrymandered so far it's now west of Los Angeles? That has to be some kind of conspiracy. Otherwise it would just be impossible.

<comment><USER21> California was stretched so far that it covers the full distance from the lowest elevation in the lower 48 to the highest summit in the lower 48.

It was also shaped so that it encompassed the driest point in the U.S.--Death Valley--and one of the wettest: 100 feet underwater below the Golden Gate Bridge.

Also, if the state of California were its own country, it would be referred to as the nation of California. True story.</comment></comment></comment></comment></comment>


17 different button configurations that were considered for the first pushbutton phones - <AUTHOR> http://www.mentalfloss.com/blogs/archives/20611

<comment><USER2> In Russia, when they were replacing public dial pay phones with pushbutton ones in '90s, they chose "Speedometer" type (I-C) for some of them. (Today most of them are replaced with proper ones, though.)

Another variation from Russia (III-A): <http://www.tema.ru/travel/komsomolsk/IMG_8694.jpg>

I-B is an interesting configuration - for churches :)</comment>


New York Times app autoplays video ads on articles even with paid subscription - <AUTHOR> https://twitter.com/james_k_nelson/status/1051404721473241088 <comment><USER2> I wrote the following in 2015:

"...people who can afford to pay for content are people with money, or people with buying power, in other words, _the exact same people advertisers look to target_. The more buying power you demonstrate, the more advertisers will target you. So the more you pay to keep ads away, the more advertisers will pay to put them back in. With the way the world currently works, _selling ads, it seems, will always be more profitable than selling content_."

Previous HN discussion: [https://news.ycombinator.com/item?id=9935803](https://news.ycombinator.com/item?id=9935803)

<comment><USER3> As a consequence, the ad-driven web is much more open and inclusive. The marginal cost of serving another page view to a Pakistani reader is zero, while a $10 subscription is a massive expense for someone who might earn just $100 a month. So if the content can be monetized by selling western eyeballs, the ad driven web works as a massive cultural redistribution to societies that can't really afford to develop similar resources in either subscription or ad- supported models.

<comment><USER2> The problem with ad-driven content is that the content is no longer 'pure' \-- it is optimized to maximize eyeballs rather than serve its purpose (e.g. news is meant to keep readers up to date with current affairs they're interested in, art and literature is meant to, well, do what art and literature do). When these things are driven by the desire to maximize advertising revenue, they take on a completely different quality.

<comment><USER4> Was any content ever 'pure'? Newspapers always relied on ad revenue, and there was always the potential for a conflict of interest there. Whether it's internet sites or papers or TV news shows, they can't afford to annoy their advertisers too much.

The only ways to avoid this are either:

A: Go with publically/government funded content, which will likely have a government bias (or one that encourages people to pay for them).

B: Go with free fan/volunteer run sources which don't have monetary interests, and that's becoming rarer and rarer nowadays.

</comment></comment></comment></comment><comment><USER5> NYT is still desperate to gets ad revenue because they've chosen a subscription model that doesn't work. The same subscription model that doesn't work for a gazillion other newspapers and magazines online, precisely because it's a gazillion-subscription model. Most people are information omnivores. Few want to pay $X/month to the New York Times _and_ $X/month to the Washington Post _and_ $X/month to the Wall Street Journal _and_ $X/month to each of a dozen other publications, just to read an average of less than one article per month on each of them. It's not just the expense, it's also the hassle of having to create logins and remember passwords for all of them, plus the security risk of having to trust every one of their IT departments not to leak your info.

I for one would be glad to pay several times the single-publication price to have a single subscription that would work across all of them, with articles on any counting against my monthly quota. I suspect I'm far from alone, but because nobody's making that offer we all continue to use ad blockers and workarounds, while the publishers continue to be desperate. That's why they keep getting in our faces like this, and also why their product is cruddier than it used to be. If we want a strong press, we need a better subscription model.

<comment><USER6>
      I for one would be glad to pay several times the single-
      publication price to have a single subscription that
      would work across all of them

Perhaps you'd like to try [https://blendle.com](https://blendle.com) ? Although it's in beta in the US, I got an invite to join the beta within minutes of expressing an interest.

Admittedly it doesn't cover _every_ publication, but you can't expect them to when it's not even out of beta yet.

<comment><USER7> Only one I didn't see there that I read commonly is Bloomberg. But they (like NYT and so many others) can be easily worked around by using an Incognito window - use up all your "free articles", close the window, open another one, here's 10 more...

Which makes me inclined to believe that, knowing it is relatively easy to work around their pay wall, they are more concerned with total eye balls than total subscriptions.

As another data point, while you can read the main Bloomberg this way, you can't read their Bloomberg Terminal Online without a horrendously expensive subscription - which I suspect reflects what the true cost of news is...

</comment></comment></comment><comment><USER8> I'm a subscriber, and like a print newspaper I'm fine with ads. Yet the online version of NYT was a large inspiration for propping a PiHole. Why? Because unlike print, the ads are blinky and distracting. And because ad blockers don't help in the NYT iOS app. So now I, a high-income subscriber, don't see your ads anymore, NYT. You pushed me too far, NYT, and the only one that suffers is _you_ , because my experience just improved.

<comment><USER9> Adguard works, too. I've been using it a while but eventually would like to try a PiHole. Do you find yourself having to adjust the settings often, or does it work fairly well?

<comment><USER8> It's pretty much fire-and-forget. Set your lists (or take the defaults), point your router DNS to the Pi-Hole, sorted. That's the simple version. You're on HN, you'll want to fiddle, but if just loaded it with default lists and never updated it, it would still probably serve well for some years.

Once in a great while I'll disable it for five minutes to look at something (Facebook or the like). But that a few button clicks.

</comment></comment></comment><comment><USER10> Contrast with the very small world of cash flow positive paid subscription sites like The Information.

2.8 million views for each and every of The Information's 730 yearly articles based on $1.90 average CPM to break even on revenue with paid subscriptions.

> The subscription model is easier with The Information because of the focus. > People know what they're getting. If you're The New York Times, not everyone > is interested in everything you do. You're just counting on people who like > your brand."

> Assuming the site makes at least 4 million from 730 stories a year, > according to some back-of-the-napkin math, the site generates about $5,500 > per article published. To earn that same amount from general display > advertising — which advisory firm Peter J. Solomon Company pegs at an > average CPM of $1.90 — each and every article The Information publishes > would need to attract more than 2.8 million ad impressions.

[https://news.ycombinator.com/item?id=15901500](https://news.ycombinator.com/item?id=15901500)

</comment><comment><USER11> What is the value proposition for the user to use the app over the website? I tend to avoid content apps because they seem to offer the company more value then the consumer. Web browser works just fine and I can more easily determine what the publisher is up to.

</comment><comment><USER12> I like NYT's articles, but have been hesitant to actually subscribe due to issues like this, and other stories where they make it hard to unsubscribe, require you call them etc.

<comment><USER8> Subscribe through iTunes or (I think) Amazon. I know on iTunes it's a flip of a switch to unsubscribe. And then run some form of PiHole to turn off the adds.

</comment></comment><comment><USER13> There is a great deal of magical thinking surrounding the idea that if you pay companies they wont exploit your data and sell you to advertisers.

This is not, and never has been true.

<comment><USER14> The way I look at it is simple.

The amount of money the content provider wants to make is price you pay + amount ads pay.

If you don't like the content, don't view it.

I removed AdBlock a few months ago because I've been talking the talk for a long time but I wanted to walk to the walk...

I take 5 seconds before watching a YouTube video, maybe 10 seconds for something unskippable, then watch 30 minutes to an hour of videos. Compare that to 30 minute tv slots with 22 minutes of content.

And it's not been a big deal. At least to me.

What do a I care that Google is tracking my preferences? What would I have to pay for a product with the kind of investment Google Search, GMail and Youtube have alone? I'm not willing to pay that.

\---

But that's me. If you have a problem with it, don't visit the sites.

If you visit and disable Js and hide half the elements, you're still consuming media from a content provider you don't support.

You still incrementing the number of page views. You're still clicking on that link and showing search engines that they're relevant.

You're supporting the content provider yet you apparently are not ok with how they fund their content?

<comment><USER15> The problem with your argument is that you unify the creator of the content and the entity placing the ad.

Supporting people via Patreon or PayPal? Donating to software? Participating in open source you use? Watching an ad embedded, vetted and filmed by the video creator (popular example: end of CinemaSins)? Buy silly merch which is actually thoughtfull? Sure thing! I always did that und will always do that!

Getting a screaming Shooter Ad from EA in the middle of my "Better sleep meditation"? Giving Sony money because I want to listen to Bethooven and they copyright-trolled that? Playing endless cat and mouse with the dark patterns added every other week to let me click on ads? Explaining my little sister what a dildo is because YouTube is busy demonitizing everyone but inappropriate scam ads? FUCK NO.

<comment><USER14> >The problem with your argument is that you unify the creator of the content and the entity placing the ad.

Please point out where I did that? I don't like having words put in my mouth.

>Getting a screaming Shooter Ad from EA in the middle of my "Better sleep meditation"?

Your "better sleep meditation" gets to choose it's platform. Ask them why they're on a platform with screaming shooter ads. I'm going to go out on a limb and say it's because they want money that screaming shooter ads pay.

>Giving Sony money because I want to listen to Bethooven and they copyright- trolled that?

Are you referring to the unwarranted _automated_ copyright strike that was sent by Sony then reversed?(admittedly after longer than it should have taken, but still)

[https://arstechnica.com/tech-policy/2018/09/sorry-sony- music...](https://arstechnica.com/tech-policy/2018/09/sorry-sony-music-you- dont-own-the-rights-to-bachs-music-on-facebook/)

Or are you talking about recordings that Sony actually has the rights for and fully has the right to make you pay for?

> Playing endless cat and mouse with the dark patterns added every other week > to let me click on ads?

Playing endless cat and mouse games with the dark patterns that let you fund the services you're using? I mean it sounds like you're using some seriously abusive service, maybe stop using it?

>Explaining my little sister what a dildo is because YouTube is busy demonitizing everyone but inappropriate scam ads? FUCK NO.

I don't see how YouTube is "demonitizing everyone but inappropriate scam ads"

Actually I can barely even parse that, you mean when the entire video is a scam ad it's less likely to be demonitized, because I find that pretty hard to believe, or you mean scam ads are demonitized? ads don't get demonitized, they just get removed, and if you keep doing that Google will just block you from making ads.

But I digress, if you let a child on the internet without adult supervision, they will find adult things. That's just the nature of the beast, ads or not. It's unforunate that happened to you and your little sister, but if you let a child on the internet there will eventually be uncomfortable things found.

What you should be doing for someone not old enough to know what something like that is is curating content and letting them consume it on a platform you're confident doesn't have anything inappropriate.

And this is anecdotal but... I don't think I've ever seen an explicit ad on YouTube, let alone YouTube Kids. Next time you see an ad that you find explicit, you can click on the information bubble and find out why it was shown, the number one reason listed is usually recent searches.

<comment><USER16> Here's where you unify the content creator and the advertiser:

> You're supporting the content provider yet you apparently are not ok with > how they fund their content?

You're saying that if you hate the sin (intrusive ads), you're not allowed to love the sinner (content).

That's bogus.

If a company wants to make itself relevant by providing content and then exploiting its visitors with ads, fine. Users have the option of exploiting the content and rejecting the ads.

YouTube is successful because people choose to generate and consume content there. There has to be some room for discussion among users about what form that consumption takes. I reject your suggestion that users have to either accept everything about the platform or go somewhere else.

On a different note, it's probably beneficial to YouTube to hear the conversation about what users block and what they dislike. Otherwise someone else will build a better mousetrap and YouTube will lose its dominance of the video sphere. This is the way business works, otherwise we'd all be connecting to Myspace via AOL and looking for the nearest Toys R Us on Mapquest.

<comment><USER14> >You're saying that if you hate the sin (intrusive ads), you're not allowed to love the sinner (content).

No. I'm not.

What's bogus is you spent this many paragraphs attacking a strawman consisting one sentence instead even one actual point I made, but I digress.

The content and the content creator are not the same.

The content doesn't "sin" and I'm sure you knew how ridiculous that sounds the moment you typed that. (But of course you also couldn't say content creator because... that's clearly not what I said.)

The _content creator_ puts their _content_ on a platform belonging to a _content provider_.

The content creator and provider both want to make money. My comment is referring to how the provider makes money (which, wouldn't you know... pays to deliver the content!).

You can support someone on Patreon that then in turn uploads to YouTube (it's not even uncommon). You're then funding to two separate entities separately.

\---

But you know what? Now that a I think about it I'd even go as far as to blame the content creator a bit more since they chose the platform.

I mean take your "better meditation" example. Is there a reason it's intentionally uploaded to the platform with mid-video ads? Then monetized it and enabled ads?

You know ads are enabled because the uploaded chooses to monetize be video right? They chose to subject you to those ads because they want money.

They didn't choose the ad, but they know video ads are allowed to interrupt their content, it's no secret.

So I won't even say they're faultless.

\---

>it's probably beneficial to YouTube to hear the conversation about what users block and what they dislike

Yeah... they already have ways to do that.

You can dislike ads, you can click the info button and let them know when a topic is no longer relevant to you.

From time to time you get ads that are just asking if you actually cared about an ad topic "Which if these have you seen an ad for recently?"

You can go into your Google profile and select interests in a much clear way than their guessing.

I do these things and now instead of a constant reminder of the car I bought months ago I get interesting movies I wouldn't have heard about otherwise, or useful products.

\---

So in summation...

>You're saying that if you hate the sin (intrusive ads), you're not allowed to love the sinner (content).

No.

>You're saying that if you hate the sin (intrusive ads), you're not allowed to _support_ the sinner (content provider) _by consuming content on their platform_.

Yes. I mean, you're allowed to do whatever you want, but the alternative is simple hypocrisy if you try and paint it as something noble meant to change how they do business.

The funny thing is I don't think Adblock in itself is hypocritical. It's just when you add in the virtue signaling and "we're just trying to make YouTube a better mousetrap!" that my eyes start to roll back into my head and the irony hits a little too hard...

</comment></comment></comment></comment></comment></comment><comment><USER17> Not only video ads. They also show regular ads to paid subscribers. If you have an ad blocker they detect it and show a request to disable it! I was pissed off because I am paid subscriber (for many years). So, I emailed them about that and they responded that their business model is based on both ad and subscription revenue.

<comment><USER18> This is why I cancelled my subscription. After a 20-minutes retention chat with a person/bot.

</comment></comment><comment><USER19> Some players adhere to the prefers-reduced-motion a11y setting and won't autoplay with that.

[https://webkit.org/blog/7551/responsive-design-for- motion/](https://webkit.org/blog/7551/responsive-design-for-motion/)

Depends on the implementation of the ads and the network they're coming from. This presently only works in Safari and Firefox nightlies.

</comment><comment><USER20> Disabling JavaScript on the NYT website completely bypasses the paywall and has few ill effects except preventing images to load (which is an acceptable trade-off).

</comment><comment><USER21> Thanks for the heads up! I was literally just thinking I miss the sunday times and was going to get the sunday paper delivered and use the online subscription throughout the week.

</comment><comment><USER22> It is sad to me that advertising has turned every browser technology available into something annoying. This has been going long since the introduction of the blink tag.

</comment><comment><USER23> And nyt print edition still contains advertising...

</comment><comment> village-idiot This is why I aggressively block ads in my household. There are basically no good actors in the ad space, and I'd prefer they all go away.

</comment><comment><USER24> Not sure what you expect? This is the internet

<comment><USER25> I think it's reasonable, and normal to expect a reduced add experience or no ads when you're a paid subscriber.

</comment></comment><comment><USER26> Just install an ad blocker and be merry. If this particular nastiness isn't caught by one of the major ad blockers, simply plug the device into Charles Proxy and capture the ad requests being made, and submit an enhancement to the ad block list.

Ezpz.

Public indignation accomplishes nothing. Direct action leads to results.

<comment><USER27> That's great if you're on the web, but as far as I know there's no way to block on ads on a native iOS app.

<comment><USER28> You really don't need an app to read a newspaper.

<comment><USER29> I use the app "safari" to block ads on the app "nytimes.com" and it works perfectly.</comment></comment></comment></comment>


Ask HN: Sparrow for Google Docs? - <AUTHOR>

I was wondering if anyone uses a native Mac app for opening and editing Google Docs similar to what Sparrow is for email?<p>I know there's Memeo, but that seems a little overkill and bloaty for my purposes. <comment><USER2> Now I just use Google Drive and open it in TextEdit or Pages.</comment>


Are you a stats junkie? - <AUTHOR> http://www.moneytized.com/are-you-a-stats-junkie/ <comment><USER2> Yes, yes. But what percentage of people are stats junkies? That's what I really want to know!</comment>


Apple records and keeps users' Siri queries for up to 2 years - <AUTHOR> http://www.latimes.com/business/technology/la-fi-tn-apple-siri-queries-20130419,0,7117017.story

<comment><USER2> I'm not quite sure why it is surprising to people that Apple keep Siri data - how else are they supposed to use the massive amounts of data to improve?

It sounds like it's not even voice data, but the questions and the answers given. This would probably be useful for optimising for things people are asking that siri is getting wrong?

<comment><USER3> It's not surprising to me that they keep it, but they do not need to keep personally identifying information for six months in order to do that. Seems a little improper, and also unnecessary, for employees to have access to that kind of thing if they're working on improving Siri.

<comment><USER2> Hazarding a guess, history associated with a user could help accuracy or determine usage that causes problems? I mean, sure, don't keep the user data forever (and I imagine you can't, depending on local laws), but as long as it's useful? Six months seems a reasonable timescale if you have to identify, track, test and implement problems, and six months per user probably doesn't give you a whole load of statistics on it's own.

<comment><USER4> Presumably. Google even desires to keep the data personalized if you opt in and allow them.

<comment><USER5> Indeed. The more data points, the better. At least for speech recognition personalization for Google Voice Search, it is opt-in: [http://support.google.com/android/bin/answer.py?hl=en&an...](http://support.google.com/android/bin/answer.py?hl=en&answer=186263)

Not so long ago, the primary goal of the 1-800-GOOG-411 service was to record people's voice queries for the purpose of bettering their voice recognition technology. After they got sufficient data samples, they discontinued the service.

[http://www.infoworld.com/t/data-management/google-wants- your...](http://www.infoworld.com/t/data-management/google-wants-your- phonemes-539)

> "Google had stated that the company originally implemented GOOG-411 to build > a large phoneme database from users' voice queries. This phoneme database, > in turn, allowed Google engineers to refine and improve the speech > recognition engine that Google uses to index audio content for searching."

<comment><USER4> Fascinating. I had no idea that's what that service was being used for. Interesting, it was more or less retired as soon as Android blew up and voice search was everywhere.

</comment></comment></comment></comment></comment></comment><comment><USER6> How else would Apple make Siri better? If they used no research on their products, the end product would be a big failure. Apple maps on release, was far from accurate. Apple maps now, a lot better.</comment>


The Zen of Passive Solar Heating Panel Design (2010) - <AUTHOR> http://www.iedu.com/Solar/Panels/index.html <comment><USER2> Here's the payout:

> This installation was completed in 2007 - and has been adequate to maintain > the indoor temperature above 65°F/18°C since that time – even though outdoor > temperatures in winter dropped below -20°F/-29°C and even though the nine- > foot by nine-foot overhead door has been opened every morning and every > evening.

> Before the end of 2009 the panels had saved more than their purchase price > in fuel costs and the owner expects that the future savings will exceed the > original cost of the entire structure. He told me he really likes starting > every day (checking his livestock) in a nice warm truck.

<comment><USER3> So what's stopping a setup like this becoming standard? It's obviously generally superior, at least for new construction that's well-insulated. Right?

<comment><USER4> They won't work very well when they don't have good southern exposure, they won't circulate a lot of heat if you have rooms and doors.

Meanwhile, the direct operating costs for natural gas heat aren't all that high.

<comment><USER5> Inserting something like this into the duct work of a normal heating or cooling system is fairly simple. The real issue is they increase construction costs and most buildings are built by people that don't use them. Further, they don't look like something out of a Norman Rockwell painting.

<comment><USER6> > most buildings are built by people that don't use them

Having rented for the past 6 years in 4 different houses, I've become convinced that this is one of the most significant factors for why so many house aren't enjoyable to live in.

Even if the overall design and layout of the house is good (I'm talking about the Christopher Alexander sense of good design), there are always small and not-so-small features that would never have been built that way had the person designing or building the house been intending to occupy it. Or had they moved in, said problems would be remedied in short order.

</comment></comment></comment></comment></comment><comment><USER7> Very interesting. I live in a place where we have significant issues with ice build up on roof surfaces, gutters, etc. One way to deal with this is to electrically heat the roof and gutters. This of course is expensive (very!). So I had the ideal that one could use the available solar energy (it is reasonably sunny in winter here) to melt the ice. My idea is not to use PV panels and restive electrical heating but to directly transfer the solar energy as heat to the ice. This would be done with some sort of heating panel, coupled to the metalic gutters with a heat pipe. Sometime I need to do some analysis to see if it is a viable idea. How to ensure snow does not cover the panel/solar heat collector is also a potential problem.

<comment><USER8> > How to ensure snow does not cover the panel/solar heat collector is also a > potential problem.

Mount the panels vertically.

<comment><USER9> Not always sufficient!

[http://c8.alamy.com/comp/D0DG83/stop-sign-covered-in-snow- du...](http://c8.alamy.com/comp/D0DG83/stop-sign-covered-in-snow-during-a- blizzard-D0DG83.jpg)

<comment><USER10> Not an insulated capture point. Backside of the example metal sign always cooled on backside by low temperature air.

</comment></comment></comment></comment><comment><USER11> I actually built a similar system as an experiment, basically a 1 x 2 x ¼ meters (multi-layered) cardboard box painted all black inside and covered with a sheet of transparent plastic on one of the larger sides. It was really cheap, around $10-15 in materials. Then I added two holes (in and out), and put some cheap flexible air duct hoses with some old CPU fan, which was another $8. On a sunny day it heats up the air incredibly well, where it actually could be beneficial during the winter season.

Unfortunately there are big problems that I encountered that I couldn't solve cheaply.

1) Mounted on the roof, it has to be sturdy enough to resist heavy rains and strong winds. We get winter windstorms, and one winter it got up to 55 knots with 70 knot gusts. I have no idea how to cheaply mount this box on the roof so it doesn't fly off and kill someone.

2) Intake and exhaust hoses would have to go either through the walls or through the windows. And since I don't own the house, my only real option would be to cut circular holes in the windows, and then replace the glass when we move out. Again, not cheap.

3) For the winter months I would have to also insulate these hoses, or they would lose most of the heat on the way to the house.

EDIT:

I also think if you don't care about what your house looks like, you can either paint it black or wrap it in black plastic.

<comment><USER12> Some people build these with painted beer can columns on the inside serving as air ducts, see this video for an example: [https://youtu.be/nuxanLdtwZQ](https://youtu.be/nuxanLdtwZQ)

They also tend to install it on the side wall; it doesn't get that much sunshine in the summer, but it becomes more efficient in the winter when the Sun stays at lower angles. External circulation of air is still required and is usually done by using an electric fan.

<comment><USER11> Yeah, I'm fully aware of that design. I've seen tests of it against a much simple design with the sheet of fabric in the middle, and there's basically no difference. Cutting so many cans' tops and bottoms is actually not an easy task, I had tried.

<comment><USER10> A couple of pieces of plywood, for each window, and some foam strips for air- flow sealing would do. This is not a big effort, just more than your (exceedingly short-lived) cardboard design contemplates.

The gain in creature-comfort in the apartment, might be more than the money saved in avoided heating, as a renter of the apartment.

</comment></comment></comment></comment><comment><USER13> For a next-level extension of this idea, check out this paper on solar closets:

[http://www.ece.villanova.edu/~nick/solar/solar.html](http://www.ece.villanova.edu/~nick/solar/solar.html)

</comment><comment><USER14> If he just made large windows out of the same double walled polycarbonate panels, wouldn't they collect just as much heat from the sun during the day? The problem with windows however is they don't insulate as well. Perhaps just doubling up or tripling their thickness would achieve the same result in the end, and be much simpler. What am I failing to understand?

<comment><USER15> _What am I failing to understand?_

You might be missing that maximizing heat collection while the sun is shining is not the goal, that too hot in the day can be just as bad as too cold at night, that each layer of "clear" polycarbonate (ie, 2 for twinwall) blocks about 10% of the light, and that gaping curtainless windows are not always a desirable architectural feature.

How many buildings have you been in that have expansive south facing windows? How many of them have been comfortable day-and-night year-round in a harsh climate without mechanical heating and cooling? Very few buildings achieve this, and I'd guess that none of them have large windows.

The Introduction to to the article is a good "introduction" to the issues. The rest of the article explains the introduction. If you are interested in the issues, it's a good article, worth reading in depth. But as the author says in the preface, "I'd suggest reading this when you're in a "learn" mode – because if you're in "skim" mode, you'll just be wasting your time."

<comment><USER16> How about Double Glazed Windows and shades?

<comment><USER15> It depends on your goals. One saying is that "a good window is still a poor wall". A quality double glazed window still has about 10x the heatloss of a well built wall. Here's a summary with a link to more: [http://www.energyvanguard.com/blog-building-science-HERS- BPI...](http://www.energyvanguard.com/blog-building-science-HERS- BPI/bid/55519/A-Good-Window-Is-Still-a-Poor-Wall)

Shades can help with privacy, but what if you want the privacy at the same time you want to be capturing heat? And if requires active control --- well, that's by definition not passive. Interestingly, the new movement in high efficiency houses is frequently for _low_ solar gain windows: well insulated windows with special coatings to admit less heat while still admitting light.

From another standpoint, gigantic expanses of windows are rarely the best way to build a pleasant room. As well as being a rare crossover between Computer Science and Building Architecture, Christopher Alexander's "A Pattern Language" has lots to say on this. Some excerpts here: [http://kk.org/cooltools/a-pattern- language/](http://kk.org/cooltools/a-pattern-language/)

Which is to say that opaque heat-gathering walls serve a purpose that is separate than that served by windows. Both have their place, and they don't tend to replace each other directly.

</comment></comment></comment></comment><comment><USER17> See also [http://www.builditsolar.com](http://www.builditsolar.com) for more recent improvements and ideas for simple passive solar.

</comment><comment><USER18> I knew about vacuum tube, but they are expensive, require a pump and something to convert the heat back from liquid to air. This on the other hand has zero moving part and requires no maintenance. Amazing!

</comment><comment><USER19> That's pretty amazing! Clearly a lot of thought and effort went into getting the design nailed down.

</comment><comment><USER20> Curious if anyone sells such panels

<comment><USER21> Mostly smaller outfits but you can find them. See e.g. [http://sunmatesolarpanels.com/content/view/2/31/](http://sunmatesolarpanels.com/content/view/2/31/)

<comment><USER20> Thanks</comment></comment></comment>


Why Java's Object.hashCode() is unsafe for use in distributed systems - <AUTHOR> http://martin.kleppmann.com/2012/06/18/java-hashcode-unsafe-for-distributed-systems.html <comment><USER2> This article is misguided, at least wrt Java. For "distributed systems" object identity needs to be created and ensured programmatically (e.g. by an object id). equals() and hashCode() must be derived from an object's immutable properties and they are as safe or unsafe as _you_ implement them.

<comment><USER3> I'm not sure if you understood the author correctly - your points don't disagree with him. He is not talking about using hashes for identity, but for routing. And he is advocating something more general than what you said. You said, basically, "implement your own hash functions for your objects." He said, basically, "don't use Object.hashCode(); you can easily just hash the serialization of the object, or implement a hash function yourself."

<comment><USER4> Except he cited specific examples of distributed systems (Hadoop, Storm) that use hashCode() but also make it quite clear you need to ensure you provide a hashCode() implementation that is entirely derived from the state of the object which is preserved in serialized form.

Seriously, it's just a bad article.

<comment><USER3> No, not _need_ to. He said it was convenient if you're already serializing the object _anyway_. Which, if you're routing an object in a distributed system, is probably true.

<comment><USER4> Yes, it is terribly convenient because if Type.hashCode() has problems with copies of objects, this will help:

        int computeHash(byte[] serializedBytes) {
            return serializeBytes.hashCode();
        }

Now you've gone from a hashCode() method that won't work if the programmer screwed the pooch, to a hashCode() method that won't work period. ;-)

[Yes, it won't be screwed up if also you use your own hash.]

The problem with serialization is you lose the semantics of the object. The "same values to the same sequence of bytes" is a tighter constraint than you might think. The same "values" might have multiple representations which are logically identical but might still be relevant in any number of ways (for example, additional information that has nothing to do with identity).

<comment><USER3> _[Yes, it won't be screwed up if also you use your own hash.]_

It's strange that you disregard that in an aside, as it's his entire point.

Personally, I prefer to implement hashes on the values inside the object, and not its serialization. They are unrelated concepts, and it helps to keep the concepts separate in the implementation. But for the purposes of routing in a distributed system - which is what the post is about - it's an acceptable solution.

<comment><USER4> > It's strange that you disregard that in an aside, as it's his entire point.

Perhaps I misunderstood as to what his point was.

If it is his entire point, I'd wish he'd not add in the bit about serialization. It just confuses the point.

To be honest, what the point of the article _is_ strikes me as confused, because he's crossing the gamut of a variety of topics even in his summary at the end. Maybe you can help me understand my reading comprehension problem. Looking at the summary I see a variety of points that aren't really related:

1) __Don't use the implementation of Object.hashCode() for your distributed hash table. __Okay, this should not be news to anyone who is at all proficient with Java. It also doesn't require a long article. I'm not sure if another article needs to be written. If one must, you can just say, "Object.equals() doesn't provide magical equivalence powers; it's a place holder for when you implement equivalence. BTW, as you'd expect, the Java standard library documents its equivalence semantics whenever it overrides the method itself." You don't even have to mention hashCode().

2) __Your serialization framework ought to be how you implement equivalence. __Umm, no. That couples the concepts serialization with equivalence. It is essentially arguing that you ought to implement equals() by first serializing both objects and then comparing their output! I'd argue they are related in the same manner as the articles description of the relationship between Object.hashCode()'s implementation and doing good distributed partition. Serialized equivalence is correlated with logical equivalence just enough to create a huge mess. Hadoop wanders about as close to this as one should by providing hooks for doing comparisons of objects without deserializing them. One should really, really NOT go down this road.

3) __Since Object.hashCode()'s implementation doesn't provide equivalence, you should not use overrides of that implementation for your partitioning. __That's just stupid, even beyond the confusion of interface and implementation. You're going to need equivalence logic for your keys. Are you really going to create your own "T.equivalent(T)" method whose behaviour is distinct from "T.equals(T)"? What does it mean when those two don't have the same value? This suggests a lack of understanding as to why Object.hashCode(Object) is there in the first place.

4) __Your distributed system needs its own hash function, but not necessarily a secure one. __Talk about getting it backwards. Built in hash mechanisms generally work fine for short circuiting equivalence tests and already make a pretty reasonable effort to deal with poor programming. In the end, using a different hash function might only help if there is a lot of entropy in the key that is being lost by the existing one, which tends to only occur with large numbers of reasonably large keys (ironically, String.hashCode() makes some pretty good trade offs here as compared to a generic hash function). This tends to be an issue that you never encounter, and to the extent that you do, it's just an optimization issue, rather than the logical one the article described. The only major hurdle that is (wisely) left on the table by built in hash tables is the security one. For tackling that you are best off using an HMAC (designed to address that space of problem) instead of a bare hash. MD5 really isn't the right choice for any case where you have a choice about your hash function, and SHA-1 really isn't any more either, so mentioning them in the article is just silly.

5) __Implementations of hashCode() generally work great for in-process hash tables, but are lousy for distributed systems. __For the vast majority of hashCode() implementations, if it provides a good in-process partition input, it provides a good out-of-process partition input. Along with its corresponding equals(Object) method, the implementation of Object.hashCode() is, by design, an exceptional case and shouldn't normally get invoked.

6) __Form parameters sent to Java web servers are a great example of this problem, and they wisely avoid the DoS problem by limiting the number of keys. __Ummm no. First, the form parameters sent to a Java web server are no more a distributed systems problem than any other user provided data shoved in to a lookup table. It's a pure trusted systems problem. The only thing 'distributed' about it is that it tends to involve a network somewhere. In fact, a web server ought to be worried about DoS problems that have nothing to do with hash tables (like, the memory footprint of the form data). Given their solution to these DoS exposures and the context, they really ought to just shove the parameters in to some kind of efficient tree.

</comment></comment></comment></comment></comment></comment></comment><comment><USER5> Please see javadoc for String.hashCode: [http://docs.oracle.com/javase/6/docs/api/java/lang/String.ht...](http://docs.oracle.com/javase/6/docs/api/java/lang/String.html#hashCode\(\))

It's true that relying on hashCode to remain stable across arbitrary objects is brittle, but this is not the case for String.

<comment><USER3> It's also true that the author made the same point.

<comment><USER5> Not quite: "On strings, numbers and collection classes, hashCode() always returns a consistent value, apparently even across different JVM vendors. It's like that despite the documentation for hashCode() explicitly not guaranteeing consistency across different processes"

String.hashCode explicitly guarantees consistency across processes by specifying how the hash code is computed, this is something that can be safely relied upon. (Same for Integer, Long, Float and Double)

</comment></comment></comment><comment><USER6> FWIW in JDK 8 hash map will most likely degrade into a lookup on a red-black tree rather than a linked list for buckets with more than 8 collisions.

<comment><AUTHOR> Interesting. But wouldn't that require keys to have an ordering (e.g. implement Comparable)?

<comment><USER7> The implementation is free to use forbidden voodoo powers. In this case it could be whatever it is also using behind the scenes to implement pointer equality for objects.

<comment><AUTHOR> Using pointer equality is fine, but doesn't help in the case where you have a custom equals() implementation. Maybe the JVM could inspect the implementation of equals() and spot certain patterns (e.g. it's the conjunction of equals() of a set of constituent objects), but doing it in general sounds impossible to me.

<comment><USER8> For hash tables where the number of buckets is much smaller than the number of hash codes (i.e. all of them) and where hash codes are well distributed and collisions are caused by different hash codes mapping onto the same bucket (not always true, but often), the tree can be implemented by comparing hash codes, with a fallback to handle the case of multiple identical hash codes.

</comment></comment></comment></comment></comment><comment><USER9> So, this is true of the CLR as well. The moral of the story is that you shouldn't assume that hashes are one-size-fits-all. Instead, design your own scheme fit for your own requirements (and no, I'm not suggesting that you write your own hash algorithm).

</comment><comment><USER10> Two wrongs don't make a right. The fact that "a".hash == "\0a" hash is an issue with the hash function. nothing else. Seeding the hash function so it is unique for each process does not solve the issue.

<comment><AUTHOR> Recent versions of Ruby also use a much better hash function. Java's hash function on strings has a slightly less trivial process for generating collisions, but it's still very easy to generate enough of them to pose a DoS risk.

Edit: actually, Java's String.hashCode() has exactly the same problem — prepending null chars doesn't change the hash code. And because the hash function is actually part of the Java standard library docs, it will probably never be changed (unlike Ruby's).

<comment><USER11> They have already announced that the hash function will be changed for Java 8 and you can enabled the change in the current version of Java 7 (u6).

[http://mail.openjdk.java.net/pipermail/core-libs- dev/2012-Ma...](http://mail.openjdk.java.net/pipermail/core-libs- dev/2012-May/010238.html)

</comment></comment></comment><comment><USER12> Overall an excellent article, but its worth mentioning that as I understand it, String's hashCode() method pre-1.3 or 1.2 (forgot exactly which version they switched over) used a different function, so it can indeed change (as the hashCode() contract allows)

<comment><USER13> It could change, but Object.hashCode(), if not overridden, is operating on the most basic type of Object with zero data members. So they pretty much have to go to the memory address for the hashing functionality, since there's no other information to hash off of. Unless they wanted to just "return 0" for every single one which would be pretty dumb.

</comment></comment><comment><USER14> In fact, in Oracle JVMs Java enum hashCode() values are almost never the same across JVM instances. This has bitten me in the past for Hadoop MapReduce jobs specifically.

</comment><comment><USER15> For the system I've been working on for the past year, most domain-ish objects extend from a class called AbstractImmutableObject which implements both hashCode() and equals() as final methods. Then, subclasses are forced to implement a "collectObjects()" method which effectively creates an array of instance variable references (plus autoboxed primitives) for a deep implementation of equality and a guaranteed consistent hash code. Immutability currently is enforced by convention, but I think FindBugs could help out. Presuming that all the instance variables in the graph of AbstractImmutableObjects are primitives or JDK objects with consistent hash functions, the resultant hashcode will be consistent as well.

[As an aside, I dislike this sort of utility base class, but it's a small price to pay for avoiding awful bugs related to hashcodes being inconsistent with equals, etc.]

I also argue that computing a hash on a serialization of an object graph is problematic as well. What are the rules for computing the hash of a serialization of a set of Strings? Must one sort the Strings before serializing them to ensure that any two Sets with the same values have the same hashcode? Sets are not required to maintain an ordering and equals() on sets ignores order (but not on SortedSet), so I would expect my "distributed" hashcode to be the same for any Set containing the same Strings. Such a scheme couples my serialization scheme tightly with my rules for equivalence. As I like to use serialization schemes written by others when possible and I don't want to eat the cost of serialization whenever I want a consistent hashcode, I'd prefer to decouple these ideas.

Recently, I've gone a step further with our domain objects and have written a generator of builders and instances using dynamic proxies (just the out-of- the-box JDK 1.3 era stuff). Developers just define interfaces, and unit tests enforce rules about what objects may be contained within the object graphs. This makes it really simple to implement things like round-trip JSON ser/deser. Because the realm of possibilities is so limited, it's easy to ensure correctness.

[As an aside, I'd love to have a DSL for such domain objects and then write a bunch of dynamic pieces parts for serialization, meta-stuff (creating a Guava function in a literate sort of way for any path through a domain object, etc.), builders, etc. I guess this is one step down the rabbit hole of model driven development, but I'm looking for something a bit lighter than, say, AndroMDA).]

</comment><comment><USER16> Isn't this why we very often override with custom hashCode and equals methods? What's the big deal..

Here's from Hibernate's WIKI on these two methods: <https://community.jboss.org/wiki/EqualsAndHashCode>

<comment><USER4> Nailed It.

</comment></comment><comment><USER4> This article and this discussion is filled with too much "missing it", so I'm writing this wordy diatribe.

tl;dr: before writing an article advising people about writing a distributed routing framework, write a distributed routing framework. Also: if your "distributed system" is also a "trusted system", realize that fusing the two together requires some genuine expertise.

To paraphrase a comment about something I wrote the other day: "that article isn't even wrong".

The protobuf reference was just ridiculous. Protobufs are not a distributed system. They're a serialization framework that is intrinsically copying (append the same Protobuf twice to the a repeated field, and when you read it back, you get two distinct objects).

        class Demo extends Object implements Cloneable {
        }

        boolean alwaysFalse(Demo a) {
            return a.equals(a.clone());
        }

No Java programmer anywhere near the level of proficiency where they are writing a distributed routing framework would be surprised by the above. Really, anyone who has bothered to read how equals(), hashCode() or HashSet/HashMap/Hashtable work in Java ought not to be surprised. Nobody expects you can throw copies of arbitrary subclasses of Object in to a hash and expect some notion of what is and is not an equivalent object to be magically discerned by the runtime (and if it isn't clear, learning about IdentityHashMap ought to bring it home).

From the article:

        On strings, numbers and collection classes, hashCode()
        always returns a consistent value, apparently even
        across different JVM vendors. It's like that despite the
        documentation for hashCode() explicitly not guaranteeing
        consistency across different processes...

The article says "hashCode()" instead of "Object.hashCode()", which just shows the author is missing what is going on. String.hashCode(), Integer.hashCode() etc. are not the same as Object.hashCode and are all documented with semantics distinct from Object.hashCode(). This is by design. It's well established design that predates Java by a good two decades too.

The article then goes on:

        The problem is that although the documentation says
        hashCode() doesn't provide a consistency guarantee,
        the Java standard library behaves as if it did provide
        the guarantee.

No. It behaves as though the users had read the actual documentation for the classes in question before using them and knows better than the library author about what the intended behaviour is.

The only surprise in protobufs is that they don't generate their own equals()/hashCode() methods to provide more flexible equivalence relations; it becomes abundantly clear as to why once you try to answer the question "well just how would you do it without adding additional semantics (at the expense of complexity and performance) to the protocol buffer language?".

The Java spec is very clear that Object.equals(Object) provides object identity as the default implementation of equality. Java 101 covers the difference in both concept and protocol between identity and equality, with the former immutable while the latter can be user defined using by overriding Object.equals(Object). Next you learn that if you do override, you need to also override hashCode() accordingly. You learn this when you use the relevant classes for the first time.

It is outright _weird_ for a Java developer to expect equivalence semantics (as opposed to identity) when invoking equals(Object) or hashCode() unless those semantics have been defined for an object's type.

This article is coming at it assbackwards from how anyone who has written a distributed routing framework in Java (or for that matter most other languages) ends up coming at it.

If you are writing a distributed routing framework, and long before you start thinking about hash algorithms, you need to define "equality and identity" semantics for your distributed objects. That invariably comes down for way to identify that two keys of some kind represent the same object. You might manage this entirely for the user, but typically you end up providing a user defined hooks because there are plenty of business rules for what is a unique identifier. In Java (as is the case in the afore mentioned Hadoop and Storm), that typically means your keys override Object.equals(Object), often with a framework provided type to tag tighter semantics.

When you overload Object.equals(Object), now you have to override Object.hashCode(). Sometimes this is missed during Java 101, but you tend not to get far in the Java world without having learned it. So once you have setup your equivalence relationship, how you correctly tackle Object.hashCode() becomes very, very straight forward.

In short: if you have reached the point where you are writing a distributed routing framework in Java that assumes Object.hashCode() is stable across the framework, you were almost certainly screwed long, long before you made that mistake.

Eventually, you get to the point where you realize that users might define a really bad hash, and you don't want to fail horribly when that happens. So, you might want to defend against it. Turns out, the JDK actually does defend against poor hashes. HashSet/HashMap/etc. tweak the hash when selecting buckets to avoid hashes with entropy in the wrong places (or more accurately, a _lack_ of entropy in the right places ;-).

Then _after_ that, you start to realize that not only are user defined hash functions likely bad in that sense, but if they have user defined data (in this case, "user" is not the developer, but the developer's "user"... so that means "incompetent" is no longer our scary adjective... it's now "untrustworthy") they are probably vulnerable to hash collision attacks. At that point, you are outside the scope of what Java's hashCode() is intended to address, so you really have to go a bit further.

There are basically four approaches, and the article appears to miss all of them (or at least glosses over them like the author doesn't see how it all fits together).

1) Don't use a hash lookup for user provided keys. Use a tree. Consider a critbit tree. Most assume this sucks until they have either reflected on the matter a fair bit, or have been schooled painfully by experience.

2) Don't let the end user define the keys.

3) Don't let the end user control/have full insight in to the hashCode() calculation. Typically this involves using an HMAC as your underlying hash function rather than a straight hash. For real security, you use an HMAC with a random "password" (kept from the user) for each hash table.

4) Letting the hash go unmodified, but randomizing bucket assignment somehow (a shared secret or a secret per hash) and blocking a user who generates more than N distinct keys (key1.equals(keys2) is false) whose hashCode()'s are equivalent, where N is a fixed number or ideally, a ratio based on their total # of keys.

What generally doesn't work is simply using a "better" hash. In some cases a simple secure (and by that I definitely don't mean MD5, and really also not SHA-1 ;-) hash can work. It works only if the user never, ever has a way to determine what the hash of a given key is (that means they can never see it or side effects of it... even in the network stack). It also means your hash function is so computationally expensive that the tree approach is likely far more efficient.

What also doesn't work is using a serialization framework to serialize the bytes in a deterministic way (it isn't clear, but it reads like the author might think protobufs are guaranteed to be deterministic, which they aren't). Serialization frameworks are, by their very nature, a horrid way to add unpredictable entropy to your data (and determinism just makes it worse). That is tantamount to padding your data with a secret in a very non- cryptographically sound way. It depends not only on keeping said secret, but also keeping the use of the serialization framework secret (effectively the "cryptographic protocol"). If you think you can keep a secret from an attacker, then save yourself the trouble and just XOR your keys with it before you hash. ;-)

In short: at no point along the way in the process should you be encountering problems where you get the wrong idea about how hashCode() works and how to use it properly in your distributed routing framework.</comment>


Ask HN: How to motivate society to plant 1t trees? - <AUTHOR> Climate change is accelerating and is an existential threat. It seems planting trees may be a partial solution. How do we start and cultivate a viral campaign to plant 1t trees? <comment><USER2> Individuals in the US can do more to fight climate change by voting[1] than by planting trees.

The scope and cost of a PR campaign that would convince people to plant trees is staggering, and there's no single entity willing to pay for it. It's an issue of government taking action and extracting the money from the companies who have profited from pollution.

1\. [https://theconversation.com/government-action-isnt-enough- fo...](https://theconversation.com/government-action-isnt-enough-for-climate- change-the-private-sector-can-cut-billions-of-tons-of-carbon-79728)

<comment><AUTHOR> I hear you on voting but we had Obama in place for eight years and we did next to nothing as a country on climate change. At best, we took some incremental steps that were totally insufficient.

<comment><USER3> I agree with you on Obama, but every time voting is brought up on HN, there is an immediate responsive implicit assumption that voting for president is the only kind of voting that exists.

Americans have opportunities to vote on many levels of government. All those votes have a potential effect on policy. One woke vote for president is not going to counteract all the other bad votes or non-votes.

Obama would have done a lot more if his feet had been held to the fire by a more progressive Congress. But climate action opponents took control of the House in the very next election, effectively ending Obama's chance to take significant action.

</comment></comment></comment><comment><USER4> Hemp would be better, btw. Because it grows faster and can be harvested twice a year. Big amount of very useful biomass for many useful products. Where at this planet all these trees should or could be planted? Where could be the most efficient place for it? Most of the trees in one big area, or better wide spread around the globe? How would it impact the actual nature and plants around? Which sort of trees? Could hemp be more efficient?

</comment><comment><USER5> probably step one is to plant some trees yourself. you'll at least see how it's done at a low level

then convince some friends to go with you. encourage them to bring their friends. and repeat this

with exponential growth, any constant number is surmountable

</comment><comment><USER6> Start with >Germinate< a Tn >seedlings<, each dime sent to the gofundme will buy a seed that will be germinated in time for phase two

</comment><comment><USER7> Make a Facebook ad campaign asking for donations.</comment>


Depression speeds up brain aging - <AUTHOR> https://www.sciencedaily.com/releases/2018/05/180524081735.htm <comment><USER2> Sad to say, life is full of positive feedback loops.

"Positive feedback" in popular usage has to do, say, with getting kudos from your boss. But from a systems perspective, positive feedback is more in line with the proverb, "The rich get richer" and its corollary (which I am coining right now): The unfortunate get more unfortunate.</comment>


Epic "Your Order Has Shipped" customer service email (2005) - <AUTHOR> http://www.davehyndman.com/cd-baby-great-customer-service-email-2.htm

<comment><USER2> OK, personal opinion only, but ...

I find this sort of thing annoying. It would be especially annoying if I bought more than one thing, unless they changed it every time. But that, in turn, would force me to read through the entire email every time just to make sure they really were just saying - it's shipped.

In short, life's short, and I've got better things to do than read through an entire, cutesy email to make sure that it's saying what I think it's saying, and not saying anything unexpected.

It's also lying. I bet they didn't do any of that.

"The Moon is a Harsh Mistress" expresses clearly the difference between "Funny Always", "Funny Once", and "Funny Never". For me, this is somewhere between the last two. I hope it doesn't catch on.

And it's not "epic".

</rant>

<comment><USER3> My opinion about this depends on the subject line. What do I care about the cutesy text as long as I can get the important information without even opening the email? ("Your CD Baby order has shipped" would be ok. Bonus points for mentioning the date of the order right there. The body of the email should definitely contain a table with the ordered products. Oh, and put the tracking number in an obvious place if you have one.)

You really shouldn't even have to open order or shipping confirmation emails. Who am I to complain when they contain a gem on those rare occasions when I open them? (Those kinds of mails seem full of legal disclaimers anyway, it's not like that additional text would confuse you.)

<comment><USER4> The subject line was "Joe - Your CD Baby Order!" when I ordered last year (but with my actual first name).

Kind of annoying because then you do have to read through all that (same message) to figure out that the order actually shipped and wasn't unavailable. Of course, the use of an exclamation mark in the subject line was a clue all was well.

</comment></comment></comment><comment><USER5> If anyone is ever struggling to translate that most idiomatic of british phrases, "taking the piss," this is pretty much a perfect example of one of its meanings.

EDIT: to expand on this, I don't see this as an attempt at humour through "cuteness," it comes across as sledgehammer-irony mocking the corporate world's shift towards conversational marketing since the 90s. Customers _know_ that corporations aren't really that personally interested in them as a person, they can't be because of their scale. This is obvious. So I see this email as a nudge-wink from CDbaby to the customer, it allows them the benefits of conversational marketing without the downsides, because irony allows them to both "say it" and "not say it" at the same time.

Savvy.

</comment><comment><USER6> I like Amazon's email. "We're writing you to let you know that your order 3984-39843234-23431-3413 has shipped. This shipment completes your order. Tracking number: 1Z2394829348938293."

That's all I need to know. I don't have time to read a novel every time I buy something.

</comment><comment><USER7> Er, that post is from 2005. CDBaby has been sending emails like that since at least 2003. Maybe they still do.

That said, I think CDBaby was probably one of the first companies to engage in conversational marketing, which includes emails that look like they're written by actual human beings. (Even if they are (were?) a little over the top.)

<comment><USER8> Re: "over the top"

Gary Halbert, one of the most infamous "over the top" copywriters ever, was using this general verbiage since at least the mid-80s. He used it with, among other things, his very famous "Family Coat of Arms" mailings, which numbered in the tens of millions. It is a well-known piece of writing among copywriters.

</comment></comment><comment><USER9> Again, can we stop with the reddit-style headlines?

<comment><AUTHOR> Sorry about that. I'm a newbie here and posted this. After seeing your comment and reading my headline, I agree that it isn't in keeping with other HN headlines. Duly noted and I will try to be sensitive to that in the future. Thanks.

</comment></comment><comment><USER10> Years ago I ordered a box set 20 Years of Dischord direct from Dischord Records. In the package was a hand written thank you note from the Dischord staff member who boxed it, who not coincidentally was one of the people included in the box set. Instant loyalty. Small and diy are strengths, not weaknesses.

</comment><comment><USER11> My initial reaction was that they were trying to act like Derek was still there. Then confusion as I saw his signature (were they still sending out the same old emails?).

Please put the year in the title if the post is old. Thanks.

<comment><AUTHOR> I'm new to HN and posted this article. Thanks for prompting me to put the year in the title for old posts. I will definitely do that in the future in the event that I post an old article. Sorry about the confusion and thanks for bringing this to my attention.

</comment></comment><comment><USER12> Personally I really like this - shows the human side to a company rather than the standard corporate spiel you receive on normal shipping notices. Agreed it could become tiresome 2nd, 3rd, 4th etc time but if they added some detection as to whether you were a first time customer - it could sway someone (such as me) to at least take notice they are that little bit different and if I received the product in a timely fashion it may prompt me to choose them again over another company. Would be something worthy of an A/B test at least - corporate vs non corporate.

</comment><comment><USER13> I'm not sure it was a great idea. The email comes off as condescending if you aren't aware of Derek Siver's personality (he is a great guy & an HN member) or haven't seen his TED talks (<http://www.ted.com/speakers/derek_sivers.html>)</comment>