[jdev] File Transfer and custom attributes

Peter Saint-Andre stpeter at stpeter.im
Wed Mar 5 09:21:16 CST 2008

Matías Rojas wrote:
> Hi,
> I’m using Stream Initiation (XEP-0095) and File Transfer (XEP-0096) to send
> a file, but I need to include additional information about the file I’m
> sending.

I'm curious: what information do you want to include? If it is of
general interest, perhaps we should update XEP-0096 to include it.

> What is the best way to send custom attributes of a file?
> Should I use DataForm?

Sure, that might work...

<iq type='set' id='offer1' to='receiver at jabber.org/resource'>
  <si xmlns='http://jabber.org/protocol/si'
    <file xmlns='http://jabber.org/protocol/si/profile/file-transfer'
      <x xmlns='jabber:x:data' type='result'>
        <field var='FORM_TYPE' type='hidden'>
      <field var='your-first-private-field'>
      <field var='your-second-private-field'>
    <feature xmlns='http://jabber.org/protocol/feature-neg'>
      <x xmlns='jabber:x:data' type='form'>
        <field var='stream-method' type='list-single'>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 7338 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://mail.jabber.org/pipermail/jdev/attachments/20080305/1c3ebcfa/attachment-0002.bin>

More information about the JDev mailing list