11 | | === Why is PJSIP licensed as GPL, and not (LGPL|MPL|BSD|choose your OSS license here)? === #non-gnu |
12 | | |
13 | | Basically we agree with FSF on this issue. Quoting the [http://www.gnu.org/licenses/gpl-faq.html GPL FAQ]: |
14 | | |
15 | | [http://www.gnu.org/licenses/gpl-faq.html#WhyUseGPL Why should I use the GNU GPL rather than other free software licenses?] |
16 | | ''Using the GNU GPL will require that all the [http://www.gnu.org/philosophy/pragmatic.html released improved versions] be free software. This means you can avoid the risk of having to compete with a proprietary modified version of your own work.'' |
17 | | |
18 | | We don't want people to take PJSIP, mess it up (erm, improve it), and keep the improvements as proprietary code. On the contrary, we want everybody to enjoy PJSIP and all its improvements, and the only way to make sure of this is by releasing PJSIP as GPL. |
19 | | |
20 | | |
21 | | === What about the "viral" nature of the GPL? === #gpl-viral |
22 | | |
23 | | People often think that using GPL-ed software means that other software linked with the GPL software have to be GPL too, hence GPL is considered as viral. '''That is not exactly true''', especially with PJSIP. When linking with PJSIP, only the application (that is based on PJSIP) has to be GPL-ed, since it is considered as derived work. Other libraries linked with PJSIP don't have to be GPL, because we specifically allow linking PJSIP with third party libraries, as long as they are listed in [/licensing.htm Third Party Software] that are allowed to be linked with PJSIP. |
24 | | |
25 | | |
26 | | === Can I develop closed source products with PJSIP? === #proprietary |
27 | | |
28 | | It depends. We use the standard GPL v2 or later for PJSIP, and GPL does allow using GPL-ed code for closed source development, '''as long as the resulting product is not redistributed''' (for example, it is only used for internal purpose). Please see [http://www.gnu.org/licenses/gpl-faq.html GPL FAQ] for more information about what can/can't be done with GPL software. |
29 | | |
30 | | Alternatively, we can discuss alternative licensing for PJSIP, please contact support@pjsip.org for details. |
| 11 | === Where can I find the latest release of PJSIP? === #latest |
| 12 | |
| 13 | The latest PJSIP is always the SVN trunk version. Please find the information on how to retrieve PJSIP from SVN in the [/download.htm PJSIP Download] and [/using.htm Getting Started] page. |
| 14 | |
| 15 | === If PJSIP is said to be small footprint, then why the source is so big? === #src-large |
| 16 | |
| 17 | It is common in all projects to have source distribution that is larger than the resulting build. This is because source distribution contains other things such as documentations and scripts. The source tarball of PJSIP v0.7 is significantly larger than v0.5 because in v0.7 we include third party libraries in their original form of distribution, so that they get proper attribution and for easier update, unlike in v.0.5 where we just picked the source files that we like and included them in PJSIP. |
| 18 | |
| 19 | === I have downloaded PJSIP source codes, now what shall I do? === #do |
| 20 | |
| 21 | First you'll need to build the sources, by following the instructions in [/using.htm Getting Started] page. |
| 22 | |
| 23 | Then you can get yourself familiar with PJSIP features by running [/pjsua.htm pjsua] application. ''pjsua'' is the reference implementation of PJSIP and PJSUA-LIB, although it doesn't have all the PJSIP features, it contains most of them. Please find ''pjsua'' documentation in [/pjsua.htm pjsua Manual] page. It is also good to get familiar with ''pjsua'' since if you'll ever get any problems with PJSIP, most likely we will ask to reproduce it with ''pjsua'', to determine whether the problem is PJSIP problem or the problem with the implementation. |
| 24 | |
| 25 | Next, I assume that you want to develop some sort of SIP applications, yes? |
| 26 | |
| 27 | Prepare your project, by following the instructions in [/using.htm#using Getting Started | Using PJSIP for Applications] documentation. The details would depend on what platform you're working on. |
| 28 | |
| 29 | Then you'll fill up the application features, by following the [/docs.htm Documentation] or by looking at [/pjsip/docs/html/page_pjsip_samples.htm PJSIP samples] or [/pjmedia/docs/html/page_pjmedia_samples.htm PJMEDIA samples]. |
| 30 | |
| 31 | Good luck! |
41 | | === Where can I find the latest release of PJSIP? === #latest |
42 | | |
43 | | The latest PJSIP is always the SVN trunk version. Please find the information on how to retrieve PJSIP from SVN in the [/download.htm PJSIP Download] and [/using.htm Getting Started] page. |
44 | | |
45 | | === If PJSIP is said to be small footprint, then why the source is so big? === #src-large |
46 | | |
47 | | It is common in all projects to have source distribution that is larger than the resulting build. This is because source distribution contains other things such as documentations and scripts. The source tarball of PJSIP v0.7 is significantly larger than v0.5 because in v0.7 we include third party libraries in their original form of distribution, so that they get proper attribution and for easier update, unlike in v.0.5 where we just picked the source files that we like and included them in PJSIP. |
| 42 | |
| 43 | ---- |
| 44 | == Licensing Questions == #licensing |
| 45 | |
| 46 | === Why is PJSIP licensed as GPL, and not (LGPL|MPL|BSD|choose your OSS license here)? === #non-gnu |
| 47 | |
| 48 | Basically we agree with FSF on this issue. Quoting the [http://www.gnu.org/licenses/gpl-faq.html GPL FAQ]: |
| 49 | |
| 50 | [http://www.gnu.org/licenses/gpl-faq.html#WhyUseGPL Why should I use the GNU GPL rather than other free software licenses?] |
| 51 | ''Using the GNU GPL will require that all the [http://www.gnu.org/philosophy/pragmatic.html released improved versions] be free software. This means you can avoid the risk of having to compete with a proprietary modified version of your own work.'' |
| 52 | |
| 53 | We don't want people to take PJSIP, mess it up (erm, improve it), and keep the improvements as proprietary code. On the contrary, we want everybody to enjoy PJSIP and all its improvements, and the only way to make sure of this is by releasing PJSIP as GPL. |
| 54 | |
| 55 | |
| 56 | === What about the "viral" nature of the GPL? === #gpl-viral |
| 57 | |
| 58 | People often think that using GPL-ed software means that other software linked with the GPL software have to be GPL too, hence GPL is considered as viral. '''That is not exactly true''', especially with PJSIP. When linking with PJSIP, only the application (that is based on PJSIP) has to be GPL-ed, since it is considered as derived work. Other libraries linked with PJSIP don't have to be GPL, because we specifically allow linking PJSIP with third party libraries, as long as they are listed in [/licensing.htm Third Party Software] that are allowed to be linked with PJSIP. |
| 59 | |
| 60 | |
| 61 | === Can I develop closed source products with PJSIP? === #proprietary |
| 62 | |
| 63 | It depends. We use the standard GPL v2 or later for PJSIP, and GPL does allow using GPL-ed code for closed source development, '''as long as the resulting product is not redistributed''' (for example, it is only used for internal purpose). Please see [http://www.gnu.org/licenses/gpl-faq.html GPL FAQ] for more information about what can/can't be done with GPL software. |
| 64 | |
| 65 | Alternatively, we can discuss alternative licensing for PJSIP, please contact support@pjsip.org for details. |
| 66 | |
| 471 | == NAT Questions == #nat-questions |
| 472 | |
| 473 | === What NAT features does PJSIP support? === #nat-features |
| 474 | |
| 475 | Quite a few: |
| 476 | - On the SIP side, PJSIP supports Symmetric Response Routing ({{{rport}}}) and STUN. |
| 477 | - On the media side, application can choose the normal UDP media transport (with STUN support) or the ICE media transport. |
| 478 | - For the media, the [/pjmedia/docs/html/group__PJMED__STRM.htm media stream] will periodically transmit RTP packets during silence period, to keep NAT binding open. Also it will disable VAD for the first few hundred milliseconds after it is started, to ''hole-punch'' any NATs in between the endpoints. Please see [/pjmedia/docs/html/group__PJMEDIA__CONFIG.htm#g691ce80f0b4f2844cb9270af4665cdc8 PJMEDIA_CODEC_MAX_SILENCE_PERIOD] and [/pjmedia/docs/html/group__PJMEDIA__CONFIG.htm#gced8a0865fc8087f217067202b575f7f PJMEDIA_STREAM_VAD_SUSPEND_MSEC] settings on how to fine tune this behavior. |
| 479 | - With ICE media transport, the transport periodically sends STUN keep-alive requests to keep NAT binding open, throughout the life of the application. The transport will also update its mapped address should the binding has changed. Note that this feature is not available for UDP media transport. |
| 480 | |
| 481 | |
| 482 | === Which STUN-bis draft does PJNATH support? === #stunbis-std |
| 483 | |
| 484 | At the time of this writing, {{{draft-ietf-behave-rfc3489bis-10}}}. But since STUN-bis (rfc3489bis) is updated often, please look at [/pjnath/docs/html/index.htm PJNATH documentation] for the most up to date information. |
| 485 | |
| 486 | === Which ICE draft does PJNATH support? === #ice-std |
| 487 | |
| 488 | At the time of this writing, {{{draft-ietf-mmusic-ice-18}}}. But since ICE is updated often, please look at [/pjnath/docs/html/index.htm PJNATH documentation] for the most up to date information. |
| 489 | |
| 490 | === Which TURN draft does PJNATH support? === #ice-std |
| 491 | |
| 492 | At the time of this writing, {{{draft-ietf-behave-turn-03}}}. But since TURN is updated often, please look at [/pjnath/docs/html/index.htm PJNATH documentation] for the most up to date information. |
| 493 | |
| 494 | === What STUN-bis features does PJNATH support? === #stun-features |
| 495 | |
| 496 | Currently everything in RFC3489bis, including {{{MESSAGE-INTEGRITY}}} and {{{FINGERPRINT}}}. However PJNATH currently does not support STUN over TCP. |
| 497 | |
| 498 | === Is there any simple STUN/TURN client which I can use to test my STUN/TURN implementation? === #simple-stun-client |
| 499 | |
| 500 | Yes. There is a simple STUN/TURN client implementation in {{{pjnath/src/pjstun-client}}} directory, which will be built by default by the {{{make}}} command. If you use Visual Studio, you can build this application from within {{{pjnath/build/pjnath.dsw}}} workspace. |
| 501 | |
| 502 | This is a simple command line program to perform as STUN or TURN client. It supports STUN, TURN, short-term or long term credential, as well as FINGERPRINT mechanism. |
| 503 | |
| 504 | === Is there any simple STUN/TURN server in the samples? === #simple-stun-client |
| 505 | |
| 506 | Yes. There is a simple STUN/TURN '''server''' implementation in {{{pjnath/src/pjstun-srv-test}}} directory, which will be built by default by the {{{make}}} command. If you use Visual Studio, you can build this application from within {{{pjnath/build/pjnath.dsw}}} workspace. |
| 507 | |
| 508 | This is a simple command line program to perform as STUN or TURN server. It supports STUN, TURN, short-term or long term credential, as well as FINGERPRINT mechanism. |
| 509 | |
| 510 | |
| 511 | ---- |
| 512 | |
590 | | '''Note:''' with default settings, pjsua will include PJNATH/ICE implementation as well as many media goodies, which you may not need in your embedded application. Hence the executable size is a bit large for ''pjsua''. |
591 | | |
592 | | The heap usage with 2 connected calls using Speex wideband codec and AEC enabled (press '''dd''' in pjsua menu): |
| 653 | '''Note:''' with default settings, pjsua will include PJNATH/ICE implementation as well as many media goodies (e.g. all codecs), statically linked with the application, which you may not need in your embedded application. Hence the executable size is a bit large for ''pjsua''. |
| 654 | |
| 655 | The heap usage with 2 connected calls using Speex wideband codec and AEC enabled (press '''dd''' in pjsua menu, and scroll up to the portion where it dumps the memory pool statistic): |
612 | | 1. '''Use your own sound device abstraction''', rather than !PortAudio. If you are porting PJSIP to an embedded platform, you may need to create your own sound device abstraction. So supposing we don't use !PortAudio and use the NULL sound device implementation ({{{PJMEDIA_SOUND_IMPLEMENTATION=PJMEDIA_SOUND_NULL_SOUND}}}, we will reduce executable size by approximately '''49 KB'''. |
613 | | |
614 | | With all above optimizations set, we now have pjsua size (still with ICE/PJNATH and all media goodies '''included''' in the executable): |
| 675 | 1. '''Use your own sound device abstraction''', rather than !PortAudio. If you are porting PJSIP to an embedded platform, you will need to create your own sound device abstraction. So supposing we don't use !PortAudio and use the NULL sound device implementation ({{{PJMEDIA_SOUND_IMPLEMENTATION=PJMEDIA_SOUND_NULL_SOUND}}}), we will reduce executable size by approximately '''49 KB'''. |
| 676 | |
| 677 | With all above optimizations set, we now have pjsua size (still with ICE/PJNATH and many media goodies like conference, WAV, etc. '''statically linked''' in the executable): |