Anyone who has read the constitution knew this would have to be the case if the Constitution was going to be upheld.
The people are to be secure in their persons and their belongings (including data), unless there is probable cause, and a court ordered warrant regarding specifics of a search.
The NSA is capturing everyone’s data, by default, with no probable cause and no warrant and then storing it all in massive data banks in Virginia and Utah. That data is then categorized and mined by all sorts of agencies...again, all without any probable cause or specific warrant.
Of course it is unconstitutional and therefore illegal.
The court didn’t actually answer the question of whether or not this is constitutional. They only ruled that it was beyond what the scope of the law passed allowed.