some helper methods in the R509 module itself