Skip to content
This project contains reference implementations of Cross-Platform Authentication client library
JavaScript HTML
Find file
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
dist Some API improvements
src
test
.bowerrc
.gitignore Add jsdoc
.jshintrc
.travis.yml
ChangeLog
Gruntfile.js
LICENSE
README.md
bower.json
package.json Version 1.1.0

README.md

cpa.js

Build Status

This project contains a library which implements the Cross-Platform Authentication protocol for Clients and is provided and maintained as reference implementation.

This software implements version 1.0 of the Cross-Platform Authentication Protocol (EBU Tech 3366)

More information on Cross-Platform Authentication: EBU Tech

Usage

Installation with Bower

Bower is a package manager for the web.

bower install cpa.js

RequireJS

You can use RequireJS in order to include the cpa.js library.

HTML:

<script data-main="js/main" src="require.js"></script>

js/main.js

require.config({
  baseUrl: 'js',
  paths: {
    'cpa': '../bower_components/cpa.js/dist/cpa.min'
  }
});

require(['cpa'], function(cpa) {
  cpa.device.registerClient('http://local.ebu.io:8001/', '1', '2', '3',
    function(err, info) {
      console.log(err, info);
    });
});

Stand-alone

You can use the cpa.js library directly in the HTML page:

<script src="cpa.js"></script>

The cpa object is used to expose the library:

<script>
   cpa.device.registerClient('http://local.ebu.io:8001/', '1', '2', '3',
     function(err, info) {
       console.log(err, info);
     });
</script>

Node.js

Install the cpa.js package using NPM:

npm install cpa.js

Use require to access within Node.js:

var cpa = require('cpa.js');

cpa.device.registerClient('http://local.ebu.io:8001/', '1', '2', '3',
     function(err, info) {
       console.log(err, info);
     });

Development

Build

npm install

bower install

grunt

Related Projects

The demonstrators below are based on this library:

Contributors

Copyright & License

Copyright (c) 2014-2015, EBU-UER Technology & Innovation

The code is under BSD (3-Clause) License. (see LICENSE.txt)

Something went wrong with that request. Please try again.