#1328 Pubsub: Node configuration not validated on node creation
Reporter
pep.
Owner
Zash
Created
Updated
Stars
★ (1)
Tags
Status-Fixed
Milestone-0.11
Priority-Medium
Type-Defect
pep.
on
What steps will reproduce the problem?
1. `pubsub_max_items` not set.
2. Create pubsub node including a `pubsub#max_items` value > 256.
<iq xmlns="jabber:client" from="pep@bouah.net/movimFoo" to="pubsub.bouah.net" type="set" id="ExWqxA"><pubsub xmlns="http://jabber.org/protocol/pubsub"><create node="meh"/><configure><x xmlns="jabber:x:data" type="submit"><field var="FORM_TYPE" type="hidden"><value>http://jabber.org/protocol/pubsub#node_config</value></field><field var="pubsub#persist_items"><value>true</value></field><field var="pubsub#deliver_payloads"><value>false</value></field><field var="pubsub#send_last_published_item"><value>on_sub</value></field><field var="pubsub#access_model"><value>open</value></field><field var="pubsub#max_items"><value>1000</value></field><field var="pubsub#title"><value>Meh.</value></field></x></configure></pubsub></iq>
What is the expected output?
<error type='modify'><not-acceptable xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/></error>
What do you see instead?
The node is created.
What version of the product are you using? On what operating system?
Prosody version: 87a1742f928d (trunk)
Zash
on
Thanks.
Changes
tags Status-Accepted Milestone-0.11
titlepubsub#max_items not validated on node creation Pubsub: Node configuration not validated on node creation
What steps will reproduce the problem? 1. `pubsub_max_items` not set. 2. Create pubsub node including a `pubsub#max_items` value > 256. <iq xmlns="jabber:client" from="pep@bouah.net/movimFoo" to="pubsub.bouah.net" type="set" id="ExWqxA"><pubsub xmlns="http://jabber.org/protocol/pubsub"><create node="meh"/><configure><x xmlns="jabber:x:data" type="submit"><field var="FORM_TYPE" type="hidden"><value>http://jabber.org/protocol/pubsub#node_config</value></field><field var="pubsub#persist_items"><value>true</value></field><field var="pubsub#deliver_payloads"><value>false</value></field><field var="pubsub#send_last_published_item"><value>on_sub</value></field><field var="pubsub#access_model"><value>open</value></field><field var="pubsub#max_items"><value>1000</value></field><field var="pubsub#title"><value>Meh.</value></field></x></configure></pubsub></iq> What is the expected output? <error type='modify'><not-acceptable xmlns='urn:ietf:params:xml:ns:xmpp-stanzas'/></error> What do you see instead? The node is created. What version of the product are you using? On what operating system? Prosody version: 87a1742f928d (trunk)
Thanks.
Changespubsub#max_items not validated on node creationPubsub: Node configuration not validated on node creationFixed in https://hg.prosody.im/trunk/rev/ec353524b739
Changes