add random mechanism to scan