properly declare public functions, and `sanitization_cb` should be declared static. fixes #409