Fully extracting blacklist_and_expire()

Since the OFDP blacklisting uses the same methods for expiry and should
also add to the historical blacklist entries, the blacklist_and_expire
function was pulled out to a common place for reuse.

Some minor formatting cleanup was done as well.

Signed-off-by: Aaron Bedra <aaron@aaronbedra.com>