What goes on it
Jam and peanut butter are liquids to TSA. Over 3.4 ounces, jam and peanut butter go in your checked bag.
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
CBP’s line is short: “You may bring bakery items and certain cheeses into the United States.”
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.”