Yes, you must watch out for cross-site scripting (XSS) attacks. This is when a malicious user injects script into your info window (or other) content, for example to steal the viewer's cookie. The solution is to ensure you HTML-escape user input at the point of constructing your info window HTML.
BenBen