1A: Congress shall make no law ... Abridging the freedom of speech. (Note: freedom of speech includes the ability to listen to what you want)
2A: ... the right of the people to keep and bear Arms, shall not be infringed.
Congress making a law that prevents minors from accesing information is a clearly a breach of the first text.
Point of sale ID checks for guns are much less clearly "infringing on the right to keep arms". It is only limiting the sale, not the ownership.