5.2.20
10/23/2019

[#284] Support XEP-0221 (Dataforms media element)
Summary Support XEP-0221 (Dataforms media element)
Queue gloox
Queue Version SVN
Type Enhancement
State Unconfirmed
Priority 1. Low
Owners
Requester pulkomandy (at) pulkomandy (dot) tk
Created 09/28/2019 (25 days ago)
Due
Updated 09/29/2019 (24 days ago)
Assigned
Resolved

History
09/29/2019 06:10:03 PM pulkomandy (at) pulkomandy (dot) tk Comment #2 Reply to this comment
For reference here is the implementation I came up with

https://github.com/HaikuArchives/Renga/blob/master/network/bob.cpp 
(from old gloox 1.1 branch that has been overwritten, with some changes)
https://github.com/HaikuArchives/Renga/blob/master/network/media.cpp
09/28/2019 09:53:22 PM pulkomandy (at) pulkomandy (dot) tk Comment #1
State ⇒ Unconfirmed
Priority ⇒ 1. Low
Type ⇒ Enhancement
Summary ⇒ Support XEP-0221 (Dataforms media element)
Queue ⇒ gloox
Reply to this comment
I'm implementing in-band registration (XEP-0077) in my client and 
found out that some servers provide a captcha image in the form they 
send. It would be nice to have this handled properly and integrated in 
the dataforms implementation in gloox.

I can do it using a separate StanzaExtension that matches the <media> 
element, but then I can't match the media element with the 
dataformfield it came from in a clean way (I can only guess by having 
my StanzaExtension parse the form item and locate the name there, then 
match using that, hoping that there is only a single field with that 
name)

It would be much simpler if the DataForms implementation in gloox 
would support the media element directly in some way (at least allow 
me to get the media URL)