Thanks for the reply, and context!
My reading of the RFCs is that PASS takes a single parameter, which (by the eBNF) should be colon prefixed if it contains a space. So it should be ok to send a password with spaces (in fact this is necessary for undernet's "register on login" functionality) as long as it's colon prefixed.
But also it's up to you whether this is a bug

I mostly wanted to document the difference between soju and mIRC and how it seems like undernet thinks the former is "more correct".