But I'd assume there's no specific law against sneaking aboard a shuttle, same as I assume there isn't one against sneaking onto a military vessel.
Um, you'd better not try it. TV shows generally aren't a good source of information on military law. The only exception I can think of is JAG, and that's not in production any more.
If you're on a US military vessel, you're subject to US military law, not civilian law, and command officers in the US Navy don't take kindly to unauthorized civilians on board their vessels. I can pretty much guarantee that you'd end up arrested and charged with violation of military law. The same stern rules apply to US military bases of any service, so whoever has jurisdiction over the shuttle would be the legal authority.
If it's civilian law, you could be charged with trespassing, breaking and entering, fraud or theft (for attempting to stow away - like on a ship or an airplane), or a number of other things. Military law - well, you're taking your future in your hands and tossing it against a wall of cheese graters. The rules of conduct and evidence in military court are far different from those in civilian court. It's easier to get a conviction and the sentences are generally harsher.