packaging: added DB validation functions

Change-Id: I25979acbf54d980168be929638ff4aed800bf6d3
Signed-off-by: Alex Lourie <alourie@redhat.com>