Earlier quoted context omitted.
The fifth amendment was only ever intended to be dealing with testimony - you couldn't be called as a witness against yourself (the history of why it exists makes this clear). That is, you literally can not be asked to testify against yourself, in a custodial interrogation, court, or other setting where it could be used as evidence against you in a criminal trial. It was never intended to prevent evidence you were st…
At least that means that I would not need to help them searching my phone. Is that correct? My phone needs a pass code to allow any interaction and I could conceivably encrypt data on it. What if I get arrested, but on grounds of the 4th amendment won't reveal the pass code? Oops. Meant to reply to cgshaw, the child comment.
This varies right now. Essentially, it depends on whether your giving the password would tell them something they can't otherwise prove, and that thing is testimonial in nature: That you maintain ownership of the item, etc.
Basically, if they can authenticate the existence of what information is on the phone, and can authenticate your ownership, you may very well be compelled to give the password. That said, they are very fact specific inquiries, and, AFAIK, the world is still up in the air here.
See U.S. v. Boucher, United States v. Fricosu, United States v. Kirschner, etc.