forked from genofire/unified-push-xmpp
docs: fix typos
This commit is contained in:
parent
42e8289f2f
commit
057f8045ed
|
@ -1,11 +1,11 @@
|
|||
# UnifiedPush over XMPP
|
||||
|
||||
[UnifiedPush](https://unifiedpush.org/) is an specification how push notifications delivered between application server and application.
|
||||
This is an implementation of the UnifiedPush specifications to delivere push notification over XMPP.
|
||||
[UnifiedPush](https://unifiedpush.org/) is an specification how push notifications delieveries between application server and application.
|
||||
This is an implementation of the UnifiedPush specifications to delievere push notification over XMPP.
|
||||
|
||||
In this project has following components:
|
||||
- **Gateway** (also called an Push Provider or [Server](https://unifiedpush.org/spec/server/)) which could be registered as an XMPP Component on an Server
|
||||
- **Distributor** for Linux using the [D-Bus Specification](https://unifiedpush.org/spec/dbus/) which implement an very small XMPP-Client to recieve the push notifications
|
||||
- **Distributor** for Linux using the [D-Bus Specification](https://unifiedpush.org/spec/dbus/) which implement an very small XMPP-Client to receive the push notifications
|
||||
|
||||
## XMPP Messages
|
||||
|
||||
|
@ -54,7 +54,7 @@ For the push notification it-self the origin `<message/>` is used with following
|
|||
</message>
|
||||
```
|
||||
|
||||
The message sender `from` should be validated from distributor, for not recieving invalid or manipulated push Messages.
|
||||
The message sender `from` should be validated from distributor, for not receiving invalid or manipulated push Messages.
|
||||
|
||||
## Wordings
|
||||
|
||||
|
|
|
@ -143,7 +143,7 @@ func (s *XMPPService) message(msgHead stanza.Message, t xmlstream.TokenReadEncod
|
|||
logger.Errorf("Error send unified push: %q", err)
|
||||
return nil
|
||||
}
|
||||
logger.Infof("recieve unified push")
|
||||
logger.Infof("receive unified push")
|
||||
|
||||
return nil
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
The gateway is an XMPP Component and Webserver.
|
||||
|
||||
The Webserver recieve notificatons from application server by using an JWT-Token as Endpoint Token.
|
||||
The Webserver receive notifications from application server by using an JWT-Token as Endpoint Token.
|
||||
The Signature JWT-Token is validated, so that only the Token generated by this gateway could be used (and no spaming over this Gateway is possible).
|
||||
The JWT-Token contains the XMPP-Address of the Distributor, so that this Gateway does not require to store anything.
|
||||
Current the JWT-Token is not encrypted like in [RFC 7516(https://tools.ietf.org/html/rfc7516) as an JWE [we are working on it](https://dev.sum7.eu/genofire/unified-push-xmpp/issues/5).
|
||||
|
|
|
@ -14,7 +14,7 @@ func Post(r *gin.Engine, ws *web.Service, xmpp *XMPPService, jwtsecret JWTSecret
|
|||
to, publicToken, err := jwtsecret.Read(c.Query("token"))
|
||||
if err != nil {
|
||||
c.JSON(http.StatusUnauthorized, web.HTTPError{
|
||||
Message: "jwt token unauthoried - or not given",
|
||||
Message: "jwt token unauthorized - or not given",
|
||||
Error: err.Error(),
|
||||
})
|
||||
return
|
||||
|
|
|
@ -154,7 +154,7 @@ func (h *XMPPUpHandler) HandleIQ(iq stanza.IQ, t xmlstream.TokenReadEncoder, sta
|
|||
log.Errorf("sending register response: %v", err)
|
||||
}
|
||||
}()
|
||||
log.Infof("recieved iq: %v", iq)
|
||||
log.Infof("received iq: %v", iq)
|
||||
|
||||
tokenData := messages.TokenData{}
|
||||
err := xml.NewTokenDecoder(t).Decode(&tokenData)
|
||||
|
@ -178,7 +178,7 @@ func (h *XMPPUpHandler) HandleIQ(iq stanza.IQ, t xmlstream.TokenReadEncoder, sta
|
|||
endpoint := h.endpoint + "/UP?token=" + endpointToken
|
||||
reply.IQ.Type = stanza.ResultIQ
|
||||
reply.Register.Endpoint = &messages.EndpointData{Body: endpoint}
|
||||
log.Debugf("generate respone: %v", endpoint)
|
||||
log.Debugf("generate response: %v", endpoint)
|
||||
return nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue