There are two main methods for xmpp file transmission:
The Protocol corresponding to 1 socks5 bytestreams is XEP-0065
The Protocol for 2 In-Band Bytestreams (ibb) is XEP-0047
The advantage of the socks5 Bytestreams method is high efficiency, but a file proxy is required for cross-network segment transmission. For example, the openfire server has a file proxy, so this is easy to implement.
The same network segment transmission can be directly connected. Generally, the initiator creates a socks5 service. When using this method, you also need to use the XEP-0095 protocol to initialize the stream. XMPPFramework
The implementation of the protocol that does not contain XEP-0095 needs to be defined by yourself.
The advantage of In-Band Bytestreams is its simplicity, but its efficiency is not high. The XMPPFramework does not contain an implementation of the XEP-0047 protocol.
There is another more advanced approach-Jingle, the relevant protocol is XEP-0166. This method was invented and published by google. This method has not been popularized yet, And XMPPFramework does not
Including the corresponding implementation. This is a great protocol and it should be very difficult to implement it.
If XMPPFramework is used for development, the easiest way to implement file transfer is sock5 Bytestreams.
The implementation of the main is to carefully look at the XEP-0095 and XEP-0065 of the two protocol documents.
Http://xmpp.org/xmpp-protocols/xmpp-extensions/