On a class of lateral boundary value problems associated with infinitesimal generators