Technically, anything can go bad. Roast walnuts can usually last a long time, usually about two months. Always store them in an air-tight container like a mason jar. For best results, taste your walnuts before roasting. If they have an acrid, sour, or bitter flavor, they are most likely already rancid and shouldn't be used. I like to store walnuts in the freezer in a freezer bag to keep them fresh longer.