WordPress.org installs are free standing. Use JavaScript on them and the only security risk is to a single blog. Not so here ate WordPress.com as this is a shared blogging platform.
Let me explain (for those who don’t already know) why WordPress.com can’t allow JavaScript on free hosted blogs on this wpMU multi-user blogging platform.
Blogs are served from {name}.wordpress.com. The WordPress cookie is delivered to any site that ends in wordpress.com. Any JavaScript on the page is legitimately allowed to look up cookies that would be sent to the domain it’s served from.
This means that if you can run JavaScript on a hosted WordPress page, you can retrieve the login cookie from another WordPress user, and then pass it to an external site. (Generally by creating an image reference that includes the encoded login cookie.)
This is just a basic part of the underlying technology of the web browser, and it’s required for sites like gmail, Yahoo!, and others to operate.
There are ways a site can avoid this problem (generally by constantly changing the login cookie data with EVERY response, and invalidating the old ones immediately), but they require more horsepower on the backend than the blogging sites are really able to provide, and there’s still usually a small window of opportunity.
This is why Livejournal, WordPress, and most other hosted sites disallow Javascript on their pages.