diff --git a/const.go b/const.go index a18b427..4717ad8 100644 --- a/const.go +++ b/const.go @@ -7,6 +7,7 @@ package main const ( VERSION = "0.4.0-devel" nsEme = "urn:xmpp:eme:0" + nsHints = "urn:xmpp:hints" nsHttpUpload = "urn:xmpp:http:upload:0" nsJabberClient = "jabber:client" nsJabberData = "jabber:x:data" diff --git a/iqstructs.go b/iqstructs.go index 6cc69f1..4d61170 100644 --- a/iqstructs.go +++ b/iqstructs.go @@ -12,6 +12,10 @@ type OxMessageElement struct { Text string `xml:",chardata"` To string `xml:"to,attr"` Id string `xml:"id,attr"` + Store struct { + Text string `xml:",chardata"` + Xmlns string `xml:"xmlns,attr"` + } `xml:"store"` Openpgp struct { Text string `xml:",chardata"` Xmlns string `xml:"xmlns,attr"` diff --git a/ox.go b/ox.go index 5f9fb3b..0a2aece 100644 --- a/ox.go +++ b/ox.go @@ -511,6 +511,7 @@ func oxEncrypt(client *xmpp.Client, oxPrivKey *crypto.Key, recipient string, } oxMessage.To = recipient oxMessage.Id = getID() + oxMessage.Store.Xmlns = nsHints oxMessage.Openpgp.Text = base64.StdEncoding.EncodeToString(pgpMessage.Data) oxMessage.Openpgp.Xmlns = nsOx oxMessage.Encryption.Xmlns = nsEme