A script should run just fine, even when included inside a form.
What exactly do you want it to do? What I see there *should* throw up an alert if the user has typed a space in the secret key field. I would bind to the "submit" event on the form instead of "click" on the button, and you probably want to return false or preventDefault() if you catch a validation error.
As for jQuery referencing the "Add Item" or "Save Changes" button, you should be able to add a script to that page either through the 'admin_items_form_tabs' filter or just through the 'admin_theme_header' hook, then refer to the button by ID or name.