Security vulnerability fixes (#327)