What kind of cereal are we talking about? Like, cereal grains or Fruity Pebbles? If you're talking about grains, I'd assume you'd be guaranteed to infect your beer, as grains are positively crawling with bacteria (which is one of the big reasons we boil the wort).
You should have done it in the mash or in the boil. The heat would have extracted flavor, and then the boil would have sterilized the wort. It's a pretty common technique in Iron Brewer comps.
I've done gingershap cookies that way for a brown ale.
You could do an extraction of the cereal by putting some in a jar of vodka for a couple days, then using a sanitized strainer/coffee filter combination strain out the solids and add the flavored vodka to the secondary, or the bottling bucket or keg at packaging time.
But honestly doing any sort of extractions like that work best with some heat to bring the flavor into the liquid medium you're extracting into.