Yes, they should.
- It annoys me to no end when people decide how my password should behave especially when it’s nonsensical. I would like more than 8 characters please.
- You should be hashing the password, so maximum character lengths and spaces at the end don’t matter.
No, you should not trim it.
- You require a user to enter the password twice (when creating it) to eliminate typing errors. Therefore a space doesn’t matter.