Yes. My interpretation was always that the scanners only extended beyond the surface of the ship, therefore by attaching itself like a limpet to the Star Destroyer's surface, it went unnoticed.
It's pretty damn obvious that it doesn't actually have a cloaking device. If it did, why would it need to attach itself like that at all?