Skip to content

Commit

Permalink
XEP-0480: Make CDATA mandatory for all elements
Browse files Browse the repository at this point in the history
The CDATA of XEP-0480's <upgrade/>, <hash/>, and <salt/> elements is
mandatory.
  • Loading branch information
weiss committed Dec 1, 2024
1 parent f555154 commit 423bc3d
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions specs/xmpp_codec.spec
Original file line number Diff line number Diff line change
Expand Up @@ -5552,19 +5552,22 @@
-xml(sasl_upgrade,
#elem{name = <<"upgrade">>,
xmlns = <<"urn:xmpp:sasl:upgrade:0">>,
module = 'xep0480',
module = 'xep0480',
cdata = #cdata{label = '$cdata',
required = true},
result = {sasl_upgrade, '$cdata'}}).

-xml(scram_upgrade_salt,
#elem{name = <<"salt">>,
xmlns = <<"urn:xmpp:scram-upgrade:0">>,
module = 'xep0480',
attrs = [#attr{name = <<"iterations">>,
label = '$iterations',
label = '$iterations',
enc = {enc_int, []},
dec = {dec_int, [1, infinity]},
required = true}],
cdata = #cdata{label = '$cdata',
required = true,
enc = {base64, encode, []},
dec = {base64, decode, []}},
result = {scram_upgrade_salt, '$iterations', '$cdata'}}).
Expand All @@ -5574,6 +5577,7 @@
xmlns = <<"urn:xmpp:scram-upgrade:0">>,
module = 'xep0480',
cdata = #cdata{label = '$data',
required = true,
enc = {base64, encode, []},
dec = {base64, decode, []}},
result = {scram_upgrade_hash, '$data'}}).
Expand Down

0 comments on commit 423bc3d

Please sign in to comment.