rebase + use new validation code