They have no brain but aren't they like almost entirely nervous system? That's all you need to feel pain; the brain just makes it more complicated than "ouch, move away from that."
If having a reaction to physical damage (like moving away) is enough to be qualified as pain, then some plants feel pain too. We studied in biology a plant that when cut/eaten by animals releases chemicals that warn plants around it and triggers them to release another chemical that interferes with animal's digestive system and make them starve (I don't remember the name of the plant unfortunately). So should we consider this as pain too ?
If reaction to physicals damage is enough to qualify as pain, a brick wall feels pain. If you damage it, it will start having holes, and eventually fall over completely.
I think at the very least you'd need some kind of learning. Pain is the stuff you learn to avoid and pleasure is the stuff you learn to do more. Without that, it's impossible to say whether an instinctive response to stimuli is a negative or positive feeling.