Where did the flood come from halo?

The Flood was actually contained inside Halo before some Covenant set them free. Their actual origins are unknown.