old thread alert... (but it's time to get that updated anyway).
Only minor nitpicks, dumped here for searchability/traceability, I'm quite happy with this otherwise.
- 2.2. does not apply to <message type=error/>. Potentially receiving any error (message for sure, maybe also presence) from the locked resource unlocks the resource.
- typing notifications should be sent to the locked resource, otherwise strange things happen. of course, typing notications are just <message/> stanzas so that should already happen, but it might be worth mentioning it.
- what happens when you receive a <message><composing/></message>? is that sufficient to lock the sender resource? I think so (which is also the current behaviour), but that should probably be documented as an additional assumption :-)
Additionally, there is a typo in section 1: "epsecially"
