GithubHelp home page GithubHelp logo

allright / nksip Goto Github PK

View Code? Open in Web Editor NEW

This project forked from netcomposer/nksip

0.0 3.0 0.0 6.71 MB

Erlang SIP application server

License: Apache License 2.0

Makefile 0.24% Python 0.09% Erlang 99.67%

nksip's Introduction

Introduction

NkSIP is an Erlang SIP framework or application server, which greatly facilitates the development of robust and scalable server-side SIP applications like proxy, registrar, redirect or outbound servers, B2BUAs, SBCs or load generators. NkSIP takes care of much of the SIP complexity, while allowing full access to requests and responses.

IMPORTANT - This version has important, incompatible changes, see the CHANGELOG - IMPORTANT

A single NkSIP instance can start any number of SIP Services, each one listening on a specific set of transports (udp, tcp, tls, sctp, ws or wss), ip addresses and ports. A Service can provide a callback module where it can implement a number of callback functions. All of them are optional, having sane defaults in case they are not implemented. For outgoing-only SIP applications, a callback module is not necessary.

NkSIP also includes a powerful plugin mechanism, that can be used to modify its behaviour without having to fully understand or modify the core engine, and with virtually zero overhead, even if the Service uses a large number of plugins.

NkSIP is very stable and robust. Thanks to its Erlang roots it can perform many actions while running: starting and stopping Services, hot code upgrades, configuration changes and even updating your application behavior, used plugins and function callbacks on the fly.

NkSIP scales automatically using all of the available cores on the machine. Using common hardware (4-core i7 MacMini), it is easy to get more than 3.000 call cycles (INVITE-ACK-BYE) or 10.000 registrations per second. A disributed, highly available version of NkSIP will be a service of the upcoming NetComposer platform.

Features

  • Full support for all curently defined SIP methods: INVITE, ACK, REGISTER, OPTIONS, INFO, UPDATE, PRACK, SUBSCRIBE, NOTIFY, REFER, PUBLISH and MESSAGE, as an UAC, an UAS or a Proxy.
  • Can be used to develop very easily any possible SIP application: endpoints, stateful proxies with serial and parallel forking, stateless proxies, B2BUAs, application servers, registrars, SBCs, load generators, etc.
  • Transports UDP, TCP, TLS, SCTP, WS and WSS (websockets) are available, all of them capable of handling thousands of simultaneous sessions.
  • Full SIP Event support.
  • A written from scratch, fully typed 100% Erlang code with few external dependencies.
  • Robust and highly scalable, using all available processor cores automatically.
  • More than 140 tests covering nearly all of the functionality.
  • Sophisticated plugin mechanism, that adds very low overhead to the core.
  • Hot, on-the-fly core and application configuration and code upgrades.
  • IPv6 support and IPv4 <-> IPv6 bridge.
  • Full support for NAPTR and SRV location, including priority and weights.
  • Dialog and SDP processing utility functions, including media start and stop detection.

Standard plugins

  • Digest Authentication.
  • Registrar Server and Automatic Registrations.
  • Event State Compositor.
  • Reliable provisional responses.
  • Session Timers
  • SIP REFER.
  • Outbound and GRUU.
  • Trace and Statistics.

Documentation

1. User Guide
2. Reference Guide
3. API Guide
4. Standard Plugins
5. Cookbook
6. Sample Applications
7. Advanced Concepts
8. Roadmap
9. Changelog
10. Presentations

Quick Start

NkSIP has been tested on OSX and Linux, using Erlang 17

> git clone https://github.com/kalta/nksip
> cd nksip
> make
> make tests

Now you can start a simple Service using the included default callback module:

> make shell
1> nksip:start(test, #{sip_listen=>"sip:all, sips:all"}).
{ok,b746wle}
2> nksip_uac:options(test1, "sip:sip2sip.info", []).
{ok,200,[]}

From this point you can read the tutorial or start hacking with the included nksip_pbx application:

> make pbx
1> nksip_pbx:start().

You could also perform a heavy-load test using the included application nksip_loadtest:

> make loadtest
1> nksip_loadtest:full().

Contributing

Please contribute with code, bug fixes, documentation fixes, testing with SIP devices or any other form. Use GitHub Issues and Pull Requests, forking this repository.

nksip's People

Contributors

kalta avatar danielwhite avatar schlagert avatar jbgledy avatar altrg avatar toharish avatar surik avatar benlangfeld avatar rumataestor avatar fjoanis avatar leokudrik avatar ttlr avatar philipstears avatar 2b-as avatar

Watchers

Andrey Syvrachev avatar James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.