go-push-server

module
v0.0.0-...-ed11692 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 6, 2013 License: BSD-3-Clause

README

go-push-server Build Status

==============

Simple Push Server in Go https://wiki.mozilla.org/WebAPI/SimplePush https://wiki.mozilla.org/WebAPI/SimplePush/Protocol

To build:

  cd go-push-server
  GOPATH=$PWD go build mozilla.org/push

To run:

  cp config-example.json config.json
  # ... edit config.json if required
  ./push

To test:

  git submodule update
  cd simplepush_test
  make
  bin/python bin/activate_this.py
  bin/python smoke_test.py
  bin/python run_all.py

The tests assume that the push server is running as the default port number and not running TLS

To test WebSockets with TLS, you will need a certificate. Here are simple instructions to create your own self-signed certificate for testing:

http://www.akadia.com/services/ssh_test_certificate.html

TLS TL;DR?

  openssl genrsa -des3 -out test.key 1024
  openssl req -new -key test.key -out test.csr
  cp test.key test.key.orig
  openssl rsa -in test.key.orig -out test.key
  openssl x509 -req -days 365 -in test.csr -signkey test.key -out test.crt

Then edit your config.json to enable TLS and point to your test certificate:

  "useTLS"           : true,
  "certFilename"     : "test.crt",
  "keyFilename"      : "test.key"

Because your certificate is self-signed, no push client will trust it yet. Open https://yourtestservername:8080/admin (https!) on your push client and, when prompted, accept the certificate and add a permanent exception.

Directories

Path Synopsis
src
go.net/dict
Package dict implements the Dictionary Server Protocol as defined in RFC 2229.
Package dict implements the Dictionary Server Protocol as defined in RFC 2229.
go.net/html
Package html implements an HTML5-compliant tokenizer and parser.
Package html implements an HTML5-compliant tokenizer and parser.
go.net/html/atom
Package atom provides integer codes (also known as atoms) for a fixed set of frequently occurring HTML strings: tag names and attribute keys such as "p" and "id".
Package atom provides integer codes (also known as atoms) for a fixed set of frequently occurring HTML strings: tag names and attribute keys such as "p" and "id".
go.net/idna
Package idna implements IDNA2008 (Internationalized Domain Names for Applications), defined in RFC 5890, RFC 5891, RFC 5892, RFC 5893 and RFC 5894.
Package idna implements IDNA2008 (Internationalized Domain Names for Applications), defined in RFC 5890, RFC 5891, RFC 5892, RFC 5893 and RFC 5894.
go.net/ipv4
Package ipv4 implements IP-level socket options for the Internet Protocol version 4.
Package ipv4 implements IP-level socket options for the Internet Protocol version 4.
go.net/proxy
Package proxy provides support for a variety of protocols to proxy network data.
Package proxy provides support for a variety of protocols to proxy network data.
go.net/publicsuffix
Package publicsuffix provides a public suffix list based on data from http://publicsuffix.org/.
Package publicsuffix provides a public suffix list based on data from http://publicsuffix.org/.
go.net/spdy
Package spdy implements the SPDY protocol (currently SPDY/3), described in http://www.chromium.org/spdy/spdy-protocol/spdy-protocol-draft3.
Package spdy implements the SPDY protocol (currently SPDY/3), described in http://www.chromium.org/spdy/spdy-protocol/spdy-protocol-draft3.
go.net/websocket
Package websocket implements a client and server for the WebSocket protocol.
Package websocket implements a client and server for the WebSocket protocol.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL