And in this case, judicial precedent follows evolving (both popular and legal) ideas of what the words in the constitution mean.
"The right of the people to be secure in their persons, houses, papers, and effects, against unreasonable searches and seizures..."
"Persons, houses, papers, and effects" has been interpreted in terms of what things a person had, excluding things that they had given someone else to hold. It was a pretty reasonable interpretation and compromise, until it was the governing case law that covered the cloud.
Legislation can limit what Federal agents are allowed to do totally irrespectively of whether those things would separately violate the constitution.
And in any case: the law is a blunt instrument. It's (usually) better as a slowly changing representation of conventions and social consensus instead of something that we make sweeping changes in (whether legislatively or judicially).