[AMOS commit] MDL-24258 backporting security fix