skysight-inc/HackerNews huggingface dataset:
I don't understand your criticism. Anyone who claims anything is "safe" has to be specific about the definition of "safe", or else they'd be making vague unsubstantiated claims.

Rust is "memory safe" per the commonly used Saraswat definition [1] (not proven yet, but the proof is in progress). This is not something we just made up.

[1]: http://www.cis.upenn.edu/~bcpierce/courses/629/papers/Sarasw...
So inaction on overflow checking in hardware is regularly justified by claims that overflow checking in software imposes only a minor performance burden (viz. OP), while inaction on overflow checking in software is justified by claims that that it imposes an unacceptable performance burden. I feel that something doesn't add up here.
> Since there is 0 security at movie theaters, I as a moviegoer would be extremely scared to go to watch this movie in it's opening week.

Think about what you are saying. "There is a group capable and willing to commit acts of terror on American soil... but now that Sony has not released the movie, I am perfectly safe".
Food is not the only thing that may cause or save you from diseases like cancer. This is a very wrong misconcept. Of course, eating healthy can sustain way better the presure and stress we are experiencing daily, but is not enough. The negative thoughts that keep coming and kept for a long time are weighing a lot more in the development of diseases. Have a look at Dr. Bruce Lipton - The Biology of Perception. I'm not talking from thin air here, my mother died this year from stage IV cancer after she did a very intense vegan diet (which was not enough, of course) + mental and relaxing therapy sessions, and unfortunately, she didn't make it. The fear and negative thoughts are the things that are killing us, wake up and don't waste your life with negative feelings like remorse, hate, fear, and so on.
NASA Rover Finds Active, Ancient Organic Chemistry on Mars
> They gave credence to every threat. Earlier in the day I was somewhat neutral on this, but now that I've had a chance to consider it I think that Sony is actually endangering our national security with this move. This is the first time in recent memory that America has been seen as caving to terrorist demands, and it can only create more disasters.

Of course given an article about a stupid, overblown reaction a stupid and overblown reaction would be the top comment. This craving of egos heavily immersed in the social news context for every popular news item be the Most Important Thing That Has Ever Happened And Nothing Will Ever Be The Same Again, paired with a never-ending need for everyone to be outraged about everything is just so tiring. Just get a hold of yourself and and chill out, ok, the world isn't over. Sony didn't just endanger your life. You're probably going to die of cancer in some hospital bed at 4pm in the afternoon a few decades from now after a pretty boring, normal life. You want excitement and danger go help a NGO in a war torn region. You're not going to find it on the pages of reddit and hacker news. This guy rolling his eyes in the vice article would probably roll his eyes at your response as well.
I think that's where bundling comes in.

You want to show the new Hunger Games movie in your theaters? Then you also have to show those duds for so and so long.
Take the Sailing Vacation of a Lifetime in the Caribbean
Meanwhile, here's how American Commitment spins the Sunlight Foundation report: 'CONSERVATIVES OPPOSED TO INTERNET REGULATION WON FCC COMMENT PERIOD BY LANDSLIDE.'

“We’re pleased that the Sunlight Foundation is finally confirming that American Commitment and Americans opposed to regulation of the Internet won the FCC comment period. Better late than never,” said Phil Kerpen, president of American Commitment.

http://www.americancommitment.org/content/conservatives-oppo...

Note how they say they 'won' the comment period, as if each letter or email counted as a vote and the FCC is obliged to treat the input quantitatively rather than qualitatively. This sort of lobbying is a win-win for the advocacy organizations that engage in it (across the political spectrum): either the government does what they want and they declare victory, or the government does not in which case they fulminate about 'the will of the people' being thwarted and do another round of fundraising/PR on the back of that. You can make quite a nice living running a 'nonprofit' like this - $175k/year is a decent salary for booking adverts using donors' money.

http://990s.foundationcenter.org/990_pdf_archive/452/4526005...
Join Benchling (YC S12) in building the operating system for life science
ISRO Launches India’s Biggest Rocket GSLV Mark III from Sriharikota
That they could starve in comfort..
I don't think SIZEOF_LONG is portable C. You would want

sizeof(long) * CHAR_BIT

instead (while at it, use sizeof(x) instead, ?and abort if sizeof(n) > sizeof(x)?)).

More importantly, I think that expression produces an int value, so if sizeof(long) > sizeof(int), that shift will produce undefined behaviour (or zero? I don't have a C standard to check that on at hand. Actually, shifting any integral type by its size in bits could well be undefined behavior)

Even if that weren't the case, that doesn't do modular arithmetic. You would want

x = (x + n) % (1 << (SIZEOF_LONG * CHAR_BIT));

and of course, that computes x+n before doing the modulus, so even that doesn't do modular arithmetic.

I think one would need custom syntax for making modular arithmetic easy in C. I would suggest something like

x += n (mod 37);

That may make parsing difficult, though, if one allows expressions after the 'mod'. Alternatively, put the 'do modular arithmetic' thing in the type:

modular(43) int x;
modular(23) int y;
int n = x + y; // error?

Summary: this is way harder than it seems. I bet people will find errors in the above that show that conclusively.

Edit: yes, it is harder. According to http://blog.regehr.org/archives/738, left-shifting a signed integer by one bit already can trigger undefined behaviour.
Dog Gets 3D Printed Legs and Runs for First Time in Life
Sony Should Send ‘The Interview’ Straight to Video on Demand
In the end, you would still have config deployments, but to the config server. And if you can push config to nodes needing it. you have one less point-of-failure, right? I'm not too familiar with the concept of a config server.
Well, that's true. All the same, I think it's a hopelessly facile analysis - the assumption that a bombing is the only possible risk scenario, for example - that's not really responsive to the underlying issue.
Ask HN: How many IPv4 addresses does Digital Ocean currently use?
IPv4 addresses is running out. One factor is because VPS are going cheap nowadays. Do you know how many IPv4 addresses does Digital Ocean currently use?
Reposting from another thread because it's more relevant here:

Here's something I am curious about: if this was NK and it is in response to The Interview, how did they get so deep so quickly? Other state sponsored hacks seem to span multiple years with multiple iterative hacks that get deeper into the target, but The Interview only wrapped shooting a year ago and wasn't really publicly known until mid 2013.
Especially when the entire movie is about killing their leader.
He was clearly wrong on this one

No, he was right. In 1996 people were just scared of using their cards online. No one big was doing it yet, consumers didn't trust anything about the end-to-end process. There are more risks now than there were then, if anything (given how many trojans and hackers there are targeting cards now), but people are used to it now.

Paypal didn't bring any particularly new technology, they just bought confidence and bigness.
Snowdrift is written in the Haskell web framework Yesod https://github.com/dlthomas/snowdrift
Other ways in which the choice of what constitutes safety is convenient: you can recurse until the stack overflows, and you can make infinite loops instead of having to prove through the type system that everything terminates. These are reasonable design decisions. If allowing silent integer overflow is the wrong choice for Rust, it's barely the wrong choice, because the costs and benefits are clearly arguable and user-specific.
> Not to re-relitigate old discussion, but (as I'm sure you know) it's now more probable that you might overflow your integers and then pass them to unsafe code

Unsafe code needs to validate its inputs. That's part of the contract of unsafe code. If your unsafe code causes memory safety errors when given MAX_INT as an input, then your unsafe code is dangerously broken regardless of how easy it is for safe code to accidentally create a MAX_INT value.
Yahoo News is very popular here in the Philippines. Most Filipinos use Yahoo Mail. Yahoo Auction and Yahoo Search(powered by Google, not Bing) are very popular websites in Japan. These are just examples of why Yahoo is still relevant.
We just launched a new feature, videos. Videos are always matched with an article, based on context. Check it out! Many more features in the works. Also incredibly excited by a partnership we'll announce soon.
Yes, we'll improve on this soon, as well as better navigation. Thanks!
Bruce Schneier weighs in.

"this is like Snowden, only with Sony."

http://motherboard.vice.com/read/bruce-schneier-sony-hackers...
This has now been fixed. We only show lower resolution images now.
Now and then I discover apparently longer-running threads in the news that I've completely missed.

Sometimes I feel embarrassed that I've missed them, but mostly I'm just happy that I have. This one seems like the latter.

This essay is good (although I don't feel as strongly about it as the author).

http://www.aaronsw.com/weblog/hatethenews

(I still like journalists and news, I just wish it would be more long-term, less 'real-time')
Google Hangouts Dialer registers for call intent,lets place calls via Hangouts
Thanks :) We've spent a lot of time on this feature, and we'll launch many more "cards" soon.
Sparse Procedural Volumetric Rendering
Kipling may be an imperialist, but he is an honest one, and certainly correct about some fundamental ugly truths of international relations.
Intercal: The Worst Programming Language Ever [video]
Presumably the (external) sites you liked you have also. I sites from your Facebook feed after liking them, hence increasing their weight. As such I guess the answer for small businesses is simple - you need an engaged audience and then Facebook is another way to reach that engaged audience.

Thinking if Facebook as an advertising medium is IMO wrong - it's like an email list to people who don't check their email.

Of course the problem is now how do you reach potential members of your audience before they become engaged?
Why make it free? I'm sure the Streisand effect is strong enough to get a lot of people to buy this movie if they released it online and/or direct to video. "Buy the movie North Korea doesn't want you to see". A pure digital release would make it pretty hard for terrorists to decide what to bomb.
Netup: Speed Up Mobile Internet
Does Rust do saturating arithmetic by default? If not, an integer overflow won't pass INT_MAX, it will pass some other int that might be a valid input to the unsafe code.
When South Carolina executed a 14-year old
Harel's Statecharts are used a lot in automotive with Stateflow, the state machine tool of Mathworks MAtlab/Simulink.
Sony Has 'No Further Release Plans' for 'The Interview'
From this[1] 2014 article:

> As of November, DigitalOcean counts a total 187,866 active users running a cloud server (or “Droplet”)

Hard to tell if the number is active users or active droplets.

[1]: http://wptavern.com/digitalocean-is-now-the-third-largest-ho...
Why limit #2 to 2^bitsize? Arithmetic modulo 86400 (or 12, 24, 60) can be handy, too (especially if there is an 'on overflow do' facility)

And people will want complex numbers, quarternions, non-Abelian groups, etc.
Tried it on my MacBook Pro 17, Yosemite.

1) I agree with the other comments, UX/UI improvement is needed.

2) Sometime when I try to 'swipe' from my trackpad, it does 'to previous page' on the tab, which is not active - next to the active tab. (two tabs opened only - when it happened, didn't try with more tabs)

3) Scrolling/Swiping speed optimisation :)

Looking forward for more updates! Thnx!
Sony hasn't capitulated. This is PR gold. Just wait for them to change their minds on down the line. The pent-up demand will drive sales far beyond anything that would have happened had they ignored the "threat."
The actual code: https://github.com/Kintaro/wtftw-core
Yes, but in practice, that's what people do: write in a language more powerful than the standard gives them. You kind of have to if you want to get anything done without driving yourself crazy. For example:

long mega_byte = 1024 * 1024 * 8; // bits per MB
long mega_bit = 1000 * 1000; // bits per megabit

If you follow the C90 standard, this code has all sorts of issues. First, // comments are not allowed. Second, identifiers are only guaranteed to have six significant characters, so the above two variables might actually be the same variable. Finally, ints are only guaranteed to be 2 bytes, so the multiplication may overflow and the program is undefined. (Assigning to longs doesn't help: the multiplication already happened.)
Very nice. The result is very suitably suspenseful and gloomy.
They should let you filter by genre.
Top10 most demanded skills on LinkedIn in 2014
Only a guess but from how its worded it seems that the storage frontend that had already entered infinite loops may have taken the tem+ hours to restart.
"JSON itself has no integer type, just a double type"

Nit - actually the JSON standard doesn't specify a precision for the number type, but most JSON implementations don't support arbitrary precision numbers.

Though the more recent RFC does have some implementation notes for interoperability.

http://rfc7159.net/rfc7159#rfc.section.6

> "This specification allows implementations to set limits on the range and precision of numbers accepted. Since software that implements IEEE 754-2008 binary64 (double precision) numbers [IEEE754] is generally available and widely used, good interoperability can be achieved by implementations that expect no more precision or range than these provide, in the sense that implementations will approximate JSON numbers within the expected precision. A JSON number such as 1E400 or 3.141592653589793238462643383279 may indicate potential interoperability problems, since it suggests that the software that created it expects receiving software to have greater capabilities for numeric magnitude and precision than is widely available."

> "Note that when such software is used, numbers that are integers and are in the range [-(253)+1, (253)-1] are interoperable in the sense that implementations will agree exactly on their numeric values."
So many people do that Microsoft keeps a knowledge base article about it:

http://support.microsoft.com/kb/257757

"We don't recommend or support it but because you want to do it anyway, here's what to consider to make it work less badly"
One of the reasons why it's so tough to figure out who was responsible for the hack is that a vast number of people dislike Sony.
It's hard to reconcile the widespread success of this blatantly and openly manipulative horseshit, with the claim that America is a self-governing nation by the people.
The relevant contract boundary isn't specifically at the edge of the unsafe block, it's at some other level like the public face of your ADT, inside which your unsafe and technically safe regions of code share the same set of invariants. It's immaterial whether the integer operation that results in overflow happens inside or outside what is technically the unsafe block, it should still be trapped. (Sorry about being unclear in that part of my previous comment.)
> In Detroit, officials say that their busts have helped raise the street price of a kilogram of cocaine to roughly $43,000 from about $30,000. “When you spike the price by one-third, I think you’ve hit the right vein of where it’s coming from,” Graveline said.

I wonder how much extra (probably petty) crime that price spike caused?
IMHO this is the best analysis of the situation.
I can't help but to add a counterpoint here for the United States. The incarceration rate in the United States is over five times that of China (although these numbers exclude prisoners in US Territories, military facilities, immigration and customs, facilities controlled by the Marshall's Service, and juvenile facilities, which would further increase the ratio). In fact, of first world nations, the United States leads every other nation for incarceration rate including Cuba, Russia, Rwanda, Belarus, and Iran.

Besides controversies related to race, America has also seen a large number of prison scandals in the past few years including:

1: kickbacks to the judicial system to pipeline truly innocent children into juvenile detention (https://en.wikipedia.org/wiki/Kids_for_cash_scandal)

2: the forced, uninformed and/or coerced sterilization of prisoners (https://www.google.com/?q=california+forced+sterilization+of...)

3: documented overuse of solitary confinement (http://americamagazine.org/issue/solitary-scandal) in some cases for 40 straight years (http://www.democracynow.org/2014/11/24/longest_serving_us_pr...)

4: a lack of legal opportunity in high density prisons for a speedy trial, even in the case of child offenders (http://www.democracynow.org/2014/10/1/accused_of_stealing_a_...) and for those with mental issues (https://en.wikipedia.org/wiki/Mark_DeFriest)

5: the premeditated use of penal labor as a cheap replacement for unskilled labor (http://www.huffingtonpost.com/2012/12/10/prison-labor_n_2272...)

6: the use of untested, classified and ineffective lethal injections on death row inmates (for example that of Joseph Wood http://en.wikipedia.org/wiki/Execution_of_Joseph_Wood)

However, the United States is not nearly as bad to journalists. If you are a foreign journalist in the US that is not liked you will be deported (Ibrahim Jassam, Jason Rezaian and Yeganeh Salehi) and/or harassed during travel (Laura Poitras) and if you are a domestic journalistic enterprise you may be surveilled (like the Associated Press surveillance scandal this administration, or the countless others from recent times). You may be aggressively prosecuted to reveal sources (ruining your ability to keep secrecy of sources and therefore trustworthiness to confidential informants) a la Risen. You may be pressured into not running certain stories (like The Washinton Post's 2004 story about the NSA mass surveillance that was pushed under the radar). You may lose access to officials or be blocked from attending or asking questions at press releases or in the converse be given access to these things for running certain stories or positive slants on them (Judith Miller, Ken Dilanian). You may be threatened with the Espionage Act for handing national documents (Glenn Greenwald). But you will probably not be directly imprisoned.
I don't think it's hard to solve the problem of memory safety and integer overflow detection at the same time.
It may not have been the work of NK, but it doesn't mean it wasn't sold to NK.
An alternate way to handle it would be to pass a law saying the IRS must accept payment in-kind for taxes on in-kind payments. I.e., the IRS can make up whatever valuation they want but you have the option to pay them in snapchat shares.
Other hacks have nothing to do with this one. Someone at Sony opened a phishing email. That about does it.
Confirm Spambots with CleanTalk
Bruce Schneier: "Someone killed 12 people and shot another 70 people at the opening night of Batman: The Dark Knight [Rises]. They kept that movie in the theaters."

But that Batman movie was a good movie. (OK, not the best of the franchise, but still OK). The plot of The Interview is "a celebrity journalist and his producer land an interview with Kim Jong-un and are instructed by the CIA to assassinate him." That sounds like a good action-adventure movie. But it was made as a comedy. Dumb. Then the plan was to release it on Christmas Day, usually a day for take-the-kids movies. Dumber.

Sony may be using this as an excuse to escape from a turkey of a movie. Of course, now we all have to see it. Probably on Netflix; it's not worth a trip to a theater.

This whole affair is in the realm of stupid, on all sides.
I think the CDN alternative would be:

Site 1 sends <script src="/foo/jquery.js" hash="SHA3:12345...">. Your browser hasn't cached this file, so it downloads jquery.js, verifies the hash and caches the contents. Site 2 sends <script src="/bar/jquery-2.5.js hash="SHA3:12345...">. The browser finds that the hash matches the cached jquery.js and loads that instead of downloading the script again.

The scripts could still be served from CDNs, but it wouldn't have to be the same one to have a cache hit. Popular libraries like jQuery would have so many hits that a CDN might not even be worth the effort. Actually the concept is so simple, it's surprising that this hasn't already been implemented unless there is a security issue that I'm not seeing.
Great article, and a common sense approach to it at last. I can't believe this myth NK is behind it is being perpetuated when facts point to someone with insider knowledge and an agenda.
Americans are mean, vicious bastards, and American prisons have nothing to with rehabilitation. Most Americans would think it's swell for first-time offenders to never see the light of day again.
> "In OS X, if you attempt to adjust DNS servers via networksetup -setdnsservers, it asks for a password.
(...)
However, if you can go into the Network settings and manually click some buttons that the system prevents you from clicking with the keyboard, you can adjust settings without a password."

Interesting hack, somewhat relieved to see that a) it's for OS X, and b) it just leverages a poor design/trade-off between security and convenience on that platform.

I suppose this kind of stuff is a good reason to disable sudo-session caching (or whatever it's called) and demand an OTP for elevating privileges [on Linux].

Looks like windows supports OTP, but only with a dedicated server handling the authentication -- does anyone know if there's an easy way to demand OTP for UAC elevation to local admin on a stand-alone windows 8.1 workstation?

[edit: for Linux/freeBSD the libpam-oath package/toolkit can be used to enable TOTP (Time Based One-time Passwords) that are compatible with Google Authenticator -- there are a lot of tutorials on how to use it with openssh (and with the new ability to demand a set of authentication methods, how to demand eg: both ssh-key and a TOTP). With a little familiarity with pam, it's easy to set up for demanding OTP for sudo. AFAIK OS X also supports pam -- but if the gui allows the system to be backdoored, there's not much point...]
Panda App – Yosemite dark mode made simple
"In this work, he used mathematical arguments to answer the following question: was it (i) a village that was taxed in the first place, and then the tax as divided between households, or (ii) the other way around, where it was a household that was originally taxed, and then the sum represented the total to be paid by the village?... Because the total received were always an integer number of (changing) monetary units, Kolmogorov proved that it was rule (ii) that was adopted"
-Probability and Statistics by Example, Volume 1.

I guess the households that paid their tax either always paid it in full, or if they paid a portion it was always an integer value?

While you're definitely more likely to get integer values in the end if everyone is taxed $1,000 rather than $999.30. It still makes me wonder how they always ended up with integers in the end.

I guess if I have to write a check to pay off a portion of an amount I'm more likely to pay $400 than 399.90. But maybe it also had something to do with how their monetary system was set up.
notifications for replies and comments that you can adjust as needed.
Scientific method: Defend the integrity of physics