What comes with it
A separate cup of dressing, salsa or soup has to be 3.4 ounces or less in your carry-on. TSA lists salsa and sauces under the liquids limit, and soups too.
Keeping it cold
An ice pack has to be frozen solid at the checkpoint. A slushy one is treated as a liquid.
Flying home from abroad
TSA’s answer covers screening at US airports. On the way home you go through the other airport’s screening first, and its rules are the ones that count there.
Coming home through US customs
A ham or turkey sandwich won’t get in. CBP says you can’t bring fresh, dried or canned meat from most foreign countries, and “you may not import food products that have been prepared with meat.” Eat it on the plane.
Without meat, CBP’s general line is that many prepared foods are admissible. The CBP specialist makes the call.
Declare it either way. USDA says declared food brings no penalty, even when it’s refused. What happens if you don’t.
TSA puts this on every entry: “The final decision rests with the TSA officer on whether an item is allowed through the checkpoint.”