├── .github
├── dependabot.yml
└── workflows
│ └── build.yml
├── .gitignore
├── .markdownlint-cli2.yaml
├── .pre-commit-config.yaml
├── LICENSE
├── Makefile
├── README.md
├── docs
├── _xcfg
│ └── mkdocs
│ │ └── css
│ │ └── custom.css
├── alphaindexes
│ ├── 3.2.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 3.3.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 3.4.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 4.0.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 4.1.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 4.2.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 4.3.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 4.4.x
│ │ ├── micommands.md
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ └── modstatistics.md
│ ├── 5.0.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.1.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.2.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.3.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.4.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.5.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.6.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.7.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 5.8.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ ├── 6.0.x
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
│ └── devel
│ │ ├── modfunctions.md
│ │ ├── modparameters.md
│ │ ├── modstatistics.md
│ │ └── rpccommands.md
├── content
│ └── old-releases.md
├── cookbooks
│ ├── 3.2.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 3.3.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 4.0.x
│ │ ├── core.md
│ │ ├── core
│ │ │ └── cfg.md
│ │ ├── pseudovariables.md
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 4.1.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 4.2.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 4.3.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ ├── transformations.md
│ │ └── transformations.png
│ ├── 4.4.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.0.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.1.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.2.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.3.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.4.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.5.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.6.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.7.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 5.8.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── 6.0.x
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ ├── devel
│ │ ├── core.md
│ │ ├── pseudovariables.md
│ │ ├── pseudovariables.png
│ │ ├── selects.md
│ │ └── transformations.md
│ └── start.md
├── devel
│ ├── active-contributors.md
│ ├── backporting-to-3.2.x.md
│ ├── breaker.png
│ ├── breaker2.1368140178.png
│ ├── breaker2.png
│ ├── ci-proposal.md
│ ├── completing_msrp.md
│ ├── completing_outbound.md
│ ├── completing_presence.md
│ ├── config-engines.md
│ ├── git-access.md
│ ├── git-commit-guidelines.md
│ ├── github-contributions.md
│ ├── how-to
│ │ ├── install-custom-path.md
│ │ ├── internal-lib.md
│ │ ├── main.md
│ │ ├── module-readme.md
│ │ └── source-tree-run.md
│ ├── irc-meetings.md
│ ├── irc-meetings
│ │ ├── 2012a.md
│ │ ├── 2012b.md
│ │ ├── 2013a.md
│ │ ├── 2013b.md
│ │ ├── 2013blog.md
│ │ ├── 2014a.md
│ │ ├── 2014alog.md
│ │ ├── 2015a.md
│ │ ├── 2015b.md
│ │ ├── 2016a-minutes.md
│ │ ├── 2016a.md
│ │ ├── 2016b.md
│ │ ├── 2017a.md
│ │ ├── 2017b.md
│ │ ├── 2018a.md
│ │ ├── 2019a.md
│ │ ├── 2019b.md
│ │ ├── 2020a.md
│ │ ├── 2020b.md
│ │ ├── 2021a.md
│ │ ├── 2022a.md
│ │ ├── 2023a.md
│ │ ├── 2024a.md
│ │ └── securityprocedure.md
│ ├── kamailio-5.0-design.md
│ ├── libcurl_integration.md
│ ├── makefile-system.md
│ ├── module-docbook-readme.md
│ ├── new-features-requests.md
│ ├── rtcweb_breaker.md
│ ├── rtpproxy-ng.md
│ ├── troubleshooting-gdb-scripts.md
│ └── update-database-schema.md
├── download
│ ├── v3.2.x-from-git.md
│ ├── v3.3.x-from-git.md
│ ├── v4.0.x-from-git.md
│ ├── v4.1.x-from-git.md
│ ├── v4.2.x-from-git.md
│ ├── v4.3.x-from-git.md
│ ├── v4.4.x-from-git.md
│ ├── v5.0.x-from-git.md
│ ├── v5.1.x-from-git.md
│ ├── v5.2.x-from-git.md
│ ├── v5.3.x-from-git.md
│ ├── v5.4.x-from-git.md
│ ├── v5.5.x-from-git.md
│ ├── v5.6.x-from-git.md
│ ├── v5.7.x-from-git.md
│ ├── v5.8.x-from-git.md
│ └── v6.0.x-from-git.md
├── embeddedapi
│ ├── 3.2.x
│ │ ├── lua.md
│ │ ├── perl.md
│ │ └── python.md
│ ├── 3.3.x
│ │ ├── lua.md
│ │ ├── mono.md
│ │ ├── perl.md
│ │ └── python.md
│ ├── 4.0.x
│ │ ├── lua.md
│ │ ├── mono.md
│ │ ├── perl.md
│ │ └── python.md
│ ├── 4.1.x
│ │ ├── java.md
│ │ ├── lua.md
│ │ ├── mono.md
│ │ ├── perl.md
│ │ └── python.md
│ ├── 4.2.x
│ │ ├── java.md
│ │ ├── lua.md
│ │ ├── mono.md
│ │ ├── perl.md
│ │ └── python.md
│ ├── 4.3.x
│ │ ├── java.md
│ │ ├── lua.md
│ │ ├── mono.md
│ │ ├── perl.md
│ │ └── python.md
│ └── devel
│ │ ├── java.md
│ │ ├── lua.md
│ │ ├── mono.md
│ │ ├── perl.md
│ │ └── python.md
├── features
│ ├── new-in-3.2.x.md
│ ├── new-in-3.3.x.md
│ ├── new-in-4.0.x.md
│ ├── new-in-4.1.x.md
│ ├── new-in-4.2.x.md
│ ├── new-in-4.3.x.md
│ ├── new-in-4.4.x.md
│ ├── new-in-5.0.x.md
│ ├── new-in-5.1.x.md
│ ├── new-in-5.2.x.md
│ ├── new-in-5.3.x.md
│ ├── new-in-5.4.x.md
│ ├── new-in-5.5.x.md
│ ├── new-in-5.6.x.md
│ ├── new-in-5.7.x.md
│ ├── new-in-5.8.x.md
│ ├── new-in-6.0.x.md
│ └── new-in-devel.md
├── history
│ ├── 09-years-ser-kamailio.md
│ └── 15-years-ser-kamailio.md
├── index.md
├── install
│ ├── 3.2.x
│ │ ├── debian.md
│ │ └── git.md
│ ├── 3.3.x
│ │ └── git.md
│ ├── 4.0.x
│ │ ├── debian.md
│ │ └── git.md
│ ├── 4.1.x
│ │ └── git.md
│ ├── 4.2.x
│ │ └── git.md
│ ├── 4.3.x
│ │ └── git.md
│ ├── 4.4.x
│ │ └── git.md
│ ├── container
│ │ └── docker.md
│ ├── devel
│ │ └── git.md
│ ├── stable
│ │ └── debian.md
│ └── upgrade
│ │ ├── 3.1.x-to-3.2.0.md
│ │ ├── 3.2.x-to-3.3.0.md
│ │ ├── 3.3.x-to-4.0.0.md
│ │ ├── 3.3.x-to-devel.md
│ │ ├── 4.0.x-to-4.1.0.md
│ │ ├── 4.1.x-to-4.2.0.md
│ │ ├── 4.2.x-to-4.3.0.md
│ │ ├── 4.3.x-to-4.4.0.md
│ │ ├── 4.4.x-to-5.0.0.md
│ │ ├── 5.0.x-to-5.1.0.md
│ │ ├── 5.1.x-to-5.2.0.md
│ │ ├── 5.2.x-to-5.3.0.md
│ │ ├── 5.3.x-to-5.4.0.md
│ │ ├── 5.4.x-to-5.5.0.md
│ │ ├── 5.5.x-to-5.6.0.md
│ │ ├── 5.6.x-to-5.7.0.md
│ │ ├── 5.7.x-to-5.8.0.md
│ │ ├── 5.8.x-to-6.0.0.md
│ │ └── stable-to-devel.md
├── kemi
│ ├── performance-tests
│ │ └── 5.2.x.md
│ └── performances.md
├── old-releases
│ └── packages
│ │ └── debs.md
├── packages
│ ├── alpinelinux.md
│ ├── debs.md
│ ├── rpms-obs.md
│ └── rpms.md
├── playground
│ └── playground.md
├── scripts
│ ├── python
│ │ └── sdp-parser.md
│ └── toc.md
├── security
│ └── policy.md
├── sidebar.md
└── tutorials
│ ├── 3.2.x
│ └── syslog.md
│ ├── auth
│ └── auth_db.md
│ ├── cmake
│ ├── commands.md
│ ├── custom.md
│ ├── default.md
│ ├── index.md
│ └── targets.md
│ ├── dns
│ └── dnssec.md
│ ├── faq
│ └── main.md
│ ├── getting-started
│ └── main.md
│ ├── ims
│ └── installation-howto.md
│ ├── kamailio-and-mongodb.md
│ ├── kamailio-flag-operations.md
│ ├── kamailio-startup-scripts.md
│ ├── mini-howto-admin
│ ├── call_forwarding.md
│ ├── ldap-user-auth.md
│ └── main.md
│ ├── security
│ ├── kamailio-security.md
│ └── security-threats.md
│ ├── tls
│ ├── howto-openssl-1-0.md
│ └── testing-and-debugging.md
│ └── troubleshooting
│ ├── coredumpfile.md
│ └── memory.md
└── fmt
├── mdbook
├── SUMMARY.md
├── book.toml
└── src
│ ├── SUMMARY.md
│ └── chapter_1.md
├── mkdocs
└── mkdocs.yml
└── pandoc
├── css
├── github-pandoc.css
├── pandoc.css
└── style.css
├── links.lua
└── template.html
/.github/dependabot.yml:
--------------------------------------------------------------------------------
1 | ---
2 | version: 2
3 | updates:
4 | - package-ecosystem: "github-actions"
5 | directory: "/"
6 | schedule:
7 | interval: "weekly"
8 | commit-message:
9 | prefix: "github: [skip ci]"
10 |
--------------------------------------------------------------------------------
/.github/workflows/build.yml:
--------------------------------------------------------------------------------
1 | ---
2 | name: checks_build
3 | on:
4 | push:
5 | branches:
6 | - main
7 | pull_request:
8 | branches:
9 | - main
10 | # Allows you to run this workflow manually from the Actions tab
11 | workflow_dispatch:
12 | jobs:
13 | check-format:
14 | runs-on: ubuntu-latest
15 | permissions:
16 | contents: read # to fetch code (actions/checkout)
17 | steps:
18 | - uses: actions/checkout@v4
19 | with:
20 | fetch-depth: 2
21 | - name: Get all changed markdown files
22 | id: changed-markdown-files
23 | uses: tj-actions/changed-files@v46
24 | with:
25 | files: |
26 | **.md
27 | since_last_remote_commit: true
28 | - uses: DavidAnson/markdownlint-cli2-action@v20
29 | with:
30 | config: .markdownlint-cli2.yaml
31 | globs: ${{ steps.changed-markdown-files.outputs.all_changed_files }}
32 | separator: ' '
33 | - name: Build
34 | uses: Tiryoh/actions-mkdocs@v0
35 | with:
36 | configfile: fmt/mkdocs/mkdocs.yml
37 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # output dir
2 | html
3 |
4 | # mdbook specific symlinks
5 | docs/SUMMARY.md
6 |
7 | # vim swaps
8 | .*.swp
9 | .*.swo
10 |
11 | # Emacs backup files
12 | *~
13 | # Emacs file locks
14 | .#*
15 | # Emacs desktop files
16 | .emacs.desktop*
17 |
18 | # MacOSX auto-generated files
19 | .DS_Store
20 |
21 | # vscode tmp files
22 | .vscode
23 |
--------------------------------------------------------------------------------
/.markdownlint-cli2.yaml:
--------------------------------------------------------------------------------
1 | config:
2 | default: true
3 | MD004:
4 | style: "sublist"
5 | MD013: false
6 | MD046: false
7 |
--------------------------------------------------------------------------------
/.pre-commit-config.yaml:
--------------------------------------------------------------------------------
1 | ---
2 | # See https://pre-commit.com for more information
3 | # See https://pre-commit.com/hooks.html for more hooks
4 | repos:
5 | - repo: https://github.com/pre-commit/pre-commit-hooks
6 | rev: v5.0.0
7 | hooks:
8 | - id: trailing-whitespace
9 | - id: end-of-file-fixer
10 | - id: check-merge-conflict
11 | - id: mixed-line-ending
12 | - id: check-added-large-files
13 | - repo: https://github.com/DavidAnson/markdownlint-cli2
14 | rev: v0.15.0
15 | hooks:
16 | - id: markdownlint-cli2-docker
17 |
--------------------------------------------------------------------------------
/Makefile:
--------------------------------------------------------------------------------
1 | # make commands to build html from markdown
2 | #
3 |
4 | # list with markdown files
5 | MDS=$(shell find docs/* -name '*.md')
6 |
7 | # pandoc variables
8 | PDOUTDIR?=html/pandoc
9 | PDHTMLS=$(patsubst %.md,$(PDOUTDIR)/%.html, $(MDS))
10 | CSS=/css/pandoc.css
11 |
12 | .PHONY : all
13 | all :
14 | @echo " available commands:"
15 | @echo " make mkdocs"
16 | @echo " make mkdocs-clean"
17 | @echo " make pandoc"
18 | @echo " make pandoc-clean"
19 |
20 | .PHONY : pandoc
21 | pandoc : $(PDHTMLS) $(PDOUTDIR)
22 | cp -R fmt/pandoc/css $(PDOUTDIR)/docs/
23 |
24 | .PHONY : pandoc-clean
25 | pandoc-clean :
26 | rm -rf $(PDOUTDIR)
27 |
28 | .PHONY : pandoc-http
29 | pandoc-http:
30 | cd html/pandoc/docs && python -m SimpleHTTPServer
31 |
32 | .PHONY : pandoc-http3
33 | pandoc-http3:
34 | cd html/pandoc/docs && python3 -m http.server
35 |
36 | $(PDOUTDIR) :
37 | mkdir -p $(PDOUTDIR)
38 |
39 | $(PDOUTDIR)/%.html : %.md $(PDOUTDIR)
40 | mkdir -p $$(dirname $@)
41 | pandoc --toc --css $(CSS) --template fmt/pandoc/template.html --lua-filter=fmt/pandoc/links.lua -t html -f markdown -s $< -o $@
42 |
43 | .PHONY : mkdocs
44 | mkdocs :
45 | mkdocs build -f fmt/mkdocs/mkdocs.yml
46 |
47 | .PHONY : mkdocs-clean
48 | mkdocs-clean :
49 | rm -rf html/mkdocs
50 |
51 | .PHONY : mdbook
52 | mdbook:
53 | rm -f docs/SUMMARY.md && cd docs && ln -s ../fmt/mdbook/SUMMARY.md && cd ..
54 | mdbook build -d ../../html/mdbook fmt/mdbook
55 | rm -f docs/SUMMARY.md
56 |
57 | .PHONY : mdbook-serve
58 | mdbook-serve:
59 | rm -f docs/SUMMARY.md && cd docs && ln -s ../fmt/mdbook/SUMMARY.md && cd ..
60 | mdbook serve --open -d ../../html/mdbook fmt/mdbook
61 | rm -f docs/SUMMARY.md
62 |
63 | .PHONY : mdbook-clean
64 | mdbook-clean :
65 | rm -rf html/mdbook
66 | rm -f docs/SUMMARY.md
67 |
68 | .PHONY : clean
69 | clean :
70 | rm -f docs/SUMMARY.md
71 | rm -rf html
72 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Kamailio Wiki #
2 |
3 | *Kamailio Wiki with content in markdown format.*
4 |
5 | - **[Browse Wiki HTML Pages On Kamailio.Org](https://www.kamailio.org/wikidocs/)**
6 |
7 | - **[Browse Wiki Pages On Github](docs/index.md)**
8 |
9 | Initial content was converted from the Dokuwiki at:
10 |
11 | -
12 |
13 | ## Support ##
14 |
15 | To update the content, make a pull request at:
16 |
17 | -
18 |
19 | The wiki pages are inside the **[docs/](docs/)** folder.
20 |
21 | Questions and discussions about the wiki content have to be done via our mailing list:
22 |
23 | - [sr-users (at) lists.kamailio.org](https://lists.kamailio.org/mailman3/postorius/lists/sr-users.lists.kamailio.org/)
24 |
25 | *Thanks for flying Kamailio!*
26 |
--------------------------------------------------------------------------------
/docs/_xcfg/mkdocs/css/custom.css:
--------------------------------------------------------------------------------
1 | #toc-collapse {
2 | padding: 0;
3 | max-height: 85vh;
4 | overflow-y: auto;
5 | }
6 | .gemoji {
7 | height: 1em;
8 | width: auto;
9 | }
--------------------------------------------------------------------------------
/docs/cookbooks/4.3.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/4.3.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/4.3.x/transformations.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/4.3.x/transformations.png
--------------------------------------------------------------------------------
/docs/cookbooks/4.4.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/4.4.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/5.0.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/5.0.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/5.1.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/5.1.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/5.2.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/5.2.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/5.3.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/5.3.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/5.6.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/5.6.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/5.7.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/5.7.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/5.8.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/5.8.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/6.0.x/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/6.0.x/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/devel/pseudovariables.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/cookbooks/devel/pseudovariables.png
--------------------------------------------------------------------------------
/docs/cookbooks/start.md:
--------------------------------------------------------------------------------
1 | # Kamailio Cookbooks
2 |
3 | See [index#cookbooks](../index.md#cookbooks)
4 |
--------------------------------------------------------------------------------
/docs/devel/breaker.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/devel/breaker.png
--------------------------------------------------------------------------------
/docs/devel/breaker2.1368140178.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/devel/breaker2.1368140178.png
--------------------------------------------------------------------------------
/docs/devel/breaker2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/kamailio/kamailio-wiki/9aa9fa49a8e6e974906068552d912db572ce55ba/docs/devel/breaker2.png
--------------------------------------------------------------------------------
/docs/devel/ci-proposal.md:
--------------------------------------------------------------------------------
1 | # Continuous Integration on Kamailio Project
2 |
3 | ## Automated Debian/Ubuntu package building
4 |
5 | The build system for Debian and Ubuntu packages service is kindly
6 | sponsored by [Sipwise](http://www.sipwise.com). Sipwise is providing the
7 | hosting and man power to create and manage this system.
8 |
9 | [deb.kamailio.org](http://deb.kamailio.org) is based on
10 | [jenkins-debian-glue](https://github.com/mika/jenkins-debian-glue)
11 | project running on AWS EC2 environment thanks to [Michael
12 | Prokop](http://michael-prokop.at/) and myself. All the needed files,
13 | scripts and info to reproduce this system is kept public at
14 | [github](https://github.com/sipwise/kamailio-deb-jenkins).
15 |
16 | - nightly builds are been built if a change is detected in the branch,
17 | once by night.
18 | - kamailiodev-nightly
19 | branch: 'master'
20 | distributions: jessie, wheezy, squeeze, precise
21 | - kamailio41-nightly
22 | branch: '4.1'
23 | distributions: jessie, wheezy, squeeze, precise
24 | - kamailio40-nightly
25 | branch: '4.0'
26 | distributions: lenny, squeeze, wheezy, lucid, precise
27 | - kamailio33-nightly
28 | branch: '3.3'
29 | distributions: lenny, squeeze, wheezy, lucid, precise
30 |
31 |
32 |
33 | - tags are been built if a new tag is detected once by night.
34 | - kamailio41
35 | branch: '\*/tags/4.1\*'
36 | distributions: jessie, wheezy, squeeze, precise
37 | - kamailio40
38 | branch: '\*/tags/4.0\*'
39 | distributions: lenny, squeeze, wheezy, lucid, precise
40 | - kamailio33
41 | branch: '\*/tags/3.3\*'
42 | distributions: lenny, squeeze, wheezy, lucid, precise
43 |
--------------------------------------------------------------------------------
/docs/devel/completing_msrp.md:
--------------------------------------------------------------------------------
1 | # MSRP relay
2 |
3 | There are a couple of features missing from the MSRP relay
4 | implementation on Kamailio. These are required for any
5 | large-scale/real-world deployment.
6 |
7 | ## REPORT generation
8 |
9 | RFC 4976 section 6.4.1 paragraph 3 states:
10 |
11 | If the Failure-Report header is "yes" or "partial", and if there is a
12 | problem processing the SEND request or if an error response is
13 | received for that SEND request, then the relay MUST respond with an
14 | appropriate error response in a REPORT back to the original source of
15 | the message.
16 |
17 | This means that when a SEND request that contains a Failure-Report:
18 | header with value of "yes" or "partial" is relayed by Kamailio we need
19 | to maintain some state so that when the TCP send fails (immediately or
20 | timeout) or we receive a failure response from the next hop, Kamailio
21 | can generate and send a REPORT back to the sender.
22 |
23 | ## SEND chunking
24 |
25 | An MSRP relay has the option of splitting large MSRP messages (including
26 | those that are already chunked) into smaller chunks. The reason is that
27 | there is no maximum size for an MSRP chunk, so it is entirely possible
28 | for a client to attempt to send a large file in a single, very-large,
29 | MSRP message. In this case it becomes important to pull the message from
30 | the receive buffer in small pieces (instead of waiting for a complete
31 | message to arrive and over-flowing the receive buffer) and relaying it
32 | in smaller chunks.
33 |
34 | Also, the flow control for MSRP is based around TCP windowing, so if you
35 | want to limit the rate that someone is sending you MSRP messages (for
36 | example during the transfer of a large file) you do so by pulling from
37 | the TCP buffer at a lower rate. One way of avoiding overloading an MSRP
38 | relay is to have fairly small TCP receive buffers thereby limiting the
39 | rate at which clients and relays can send data. However, if the TCP
40 | buffers are small the chances of a client sending a message or chunk
41 | that is too large (and needs to be chunked by the relay) increases
42 | further.
43 |
44 | Of course, to do this the MSRP module will need to be able to remember
45 | the (From\|To)-Path, transaction ID, and so on from the start of the
46 | MSRP message so that it can use these (along with calculated Byte-Range)
47 | in each additional chunk.
48 |
49 | I was thinking a new parameter indicating the maximum MSRP send chunk
50 | size is required. If an MSRP message in the receive buffer reaches that
51 | number then it has to be pulled from the buffer in parts and relayed as
52 | multiple chunks. This maximum send chunk size should be set to be much
53 | smaller than the TCP receive buffer size.
54 |
--------------------------------------------------------------------------------
/docs/devel/completing_outbound.md:
--------------------------------------------------------------------------------
1 | # outbound
2 |
3 | This page contains some notes describing the work to fully complete
4 | outbound (RFC 5626) support on Kamailio. It is believed that the current
5 | Kamailio feature set is sufficient to provide separate Edge Proxy and
6 | Registrar servers supporting outbound.
7 |
8 | ## Single-server (combined edge proxy and registrar)
9 |
10 | - registrar module
11 | - Update lookup() so that (in single-server mode) Path: header
12 | from location table is added as a Record-Route:. If parallel
13 | forking is in use each branch must have a different
14 | Record-Route: added. lookup() must also set $du based on the
15 | flow-token from the Record-Route: header it adds for that
16 | branch.
17 | - tm module
18 | - Update t\_\*\_contacts() functions so they will work with the
19 | new lookup() behaviour in single-server mode.
20 | - rr module
21 | - Update loose_route() to cope with the double-RR that the new
22 | lookup() behaviour causes. The first Record-Route: added to a
23 | dialog forming request will have been added when the request
24 | arrived on the server and contains a flow-token pointing to the
25 | originator of the request. The second Record-Route: added is the
26 | one created by lookup() and contains a flow-token pointing to
27 | the destination of the branch.
28 | - nathelper module
29 | - Move nat_uac_test() to another module (perhaps siputils?)
30 | enabling Kamailio users to choose between the two different NAT
31 | traversal mechanisms cleanly by loading either the nathelper
32 | module or the outbound module.
33 |
34 | ## Other work to be considered
35 |
36 | - Within dialog flow fail-over
37 | - Is this even possible?
38 |
--------------------------------------------------------------------------------
/docs/devel/completing_presence.md:
--------------------------------------------------------------------------------
1 | # Presence proposal
2 |
3 | There are a several of features missing from the presence implementation
4 | on Kamailio. These are not required for all deployments, but are listed
5 | here to provide a check-list showing what needs to be done before the
6 | presence modules can be considered complete.
7 |
8 | ## Presence
9 |
10 | - GEOPRIV
11 | - External references in org.openmobilealliance.pres-rules documents
12 | (need to handle org.oma.pres-rules and pres-rules as different
13 | document types)
14 | - Polled presence (out-of-dialog SUBSCRIBE with Expires: 0)
15 | - Watcher filtering (XML in SUBSCRIBE body describing what parts of a
16 | presentity should be notified)
17 | - Anonymous fetch
18 | - Capabilities and user discovery
19 | - Partial notification
20 |
21 | ## RLS
22 |
23 | - External references in resource-list documents
24 | - Polled presence (out-of-dialog SUBSCRIBE with Expires: 0)
25 | - Watcher filtering (XML in SUBSCRIBE body describing what parts of a
26 | presentity should be notified)
27 | - Anonymous fetch
28 | - Capabilities and user discovery
29 | - Partial notification
30 |
31 | ## XCAP Client
32 |
33 | - does not use conditional requests (ETag:, If-Match:, If-Not-Match:)
34 | - does not support xcap-diff (could be implemented using PUA)
35 |
36 | ## XCAP Server
37 |
38 | - does not support xcap-diff
39 | - does not support XQuery
40 | - does not support many org.openmobilealliance auids
41 |
--------------------------------------------------------------------------------
/docs/devel/git-access.md:
--------------------------------------------------------------------------------
1 | # Developer Git Access
2 |
3 | Anyone that has relevant contributions (consistent patches, new modules,
4 | a.s.o.) to Kamailio can get Git write access to commit directly to our
5 | source code repository hosted at git.sip-router.org .
6 |
7 | ## Cloning Repository for Write Operations
8 |
9 | Each developer has a user ID for accessing the repository via ssh,
10 | which allow push operations. Cloning can be done via command:
11 |
12 | git clone ssh://USERID@git.sip-router.org/kamailio
13 |
14 | ## Branches
15 |
16 | Kamailio repository branches are categorized in:
17 |
18 | - project main branches
19 | - private developer branches
20 | - common temporary branches
21 |
22 | All of them are accessible in read only mode to everyone.
23 |
24 | ### Main Branches
25 |
26 | #### Development Branch
27 |
28 | The branch used for development version is named **master**.
29 |
30 | The commits here must be fixes and features targeting next major
31 | release.
32 |
33 | #### Stable Branches
34 |
35 | These branches are created for each major release of Kamailio. The name
36 | follows the pattern X.Y, when both X and Y are numbers, representing the
37 | first two numbers from Kamailio version. A typical Kamailio version is
38 | formed from three numbers, X.Y.Z, where Z denotes the minor version
39 | number of a major release.
40 |
41 | For example, 4.1.4 is released from branch 4.1. Same was done for 4.1.0,
42 | 4.1.1, a.s.o.
43 |
44 | Last two stable versions are maintained, therefore any bug has to be
45 | fixed in both, when appropriate.
46 |
47 | There MUST NOT be any commit adding a new feature in a stable branch.
48 | ONLY bug fixes. Improvements to documentation or adjacent helper tools
49 | are allowed.
50 |
51 | Typical way of fixing a bug that needs to be backported:
52 |
53 | - commit the patch to master branch
54 | - cherry pick it to last stable branch
55 | - cherry pick from last stable branch to previous stable branch
56 |
57 | ### Private Branches
58 |
59 | Each developer can push commits to branches that don't allow other
60 | developers to push.
61 |
62 | A developer private branch must have the name in the format
63 | **userid/branchname**, where user id is developer's commit username.
64 |
65 | For example, Alice can use **alice/testingx**. Pushing local master
66 | branch to remote **alice/testingx**:
67 |
68 | git push origin master:alice/testingx
69 |
70 | These branches are useful when doing experimental things that might not
71 | get to master after all or during testing period before releasing a
72 | major version when committing to **master** branch is frozen.
73 |
74 | Such branches must be deleted once they are merged to master branch or
75 | not used anymore.
76 |
77 | ### Private Branches
78 |
79 | These branches allow all developers to push commits to them. The name of
80 | such branch must be **tmp/branchname**.
81 |
82 | Pushing local master branch to remote branch **tmp/testingx**:
83 |
84 | git push origin master:tmp/testingx
85 |
86 | This kind of branch is recommended when many developers experiment with
87 | new code that might not get to **master** branch after all.
88 |
89 | ## Commit Recommendations
90 |
91 | - whenever there are patches for modules maintained by other
92 | developers, it is better to discuss them on
93 | mailing list before pushing them to
94 | remote repository. The patch can be:
95 | - submitted as attachment to mailing list
96 | - uploaded to the tracker at:
97 | -
98 | - pushed first in a private branch
99 | - patches to own modules can be pushed at any time. However, if you
100 | want to discuss on sr-dev mailing lists, you are welcome to send an
101 | email
102 |
103 | ## Further Guidelines
104 |
105 | Several tutorials about committing with Git and backporting are
106 | available at:
107 |
108 | - [Guidelines TOC](../index.md#guidelines)
109 |
--------------------------------------------------------------------------------
/docs/devel/github-contributions.md:
--------------------------------------------------------------------------------
1 | # Kamailio Contributions via Github
2 |
3 | ## Overview
4 |
5 | Kamailio is a community managed project, with developers world wide. Any
6 | contribution to code or documentation is very welcome.
7 |
8 | In order to be easily able to track the changes and have a coherent
9 | Changelog and commit history, there are several rules required for each
10 | contribution.
11 |
12 | Have a look to the file in our GitHub repository for the complete
13 | information about this:
14 | [CONTRIBUTING.md](https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md)
15 |
16 | See also:
17 |
18 | -
19 | -
20 |
21 | More information about the git workflow for Kamailio can be also found
22 | at the wiki page [GIT Commit Guidelines](../devel/git-commit-guidelines.md) -
23 | it is recommended you read that one as well.
24 |
25 | ## Further Assistance
26 |
27 | For any question, do not hesitate to contact other developers via
28 | mailing list:
29 |
30 | - ****
31 |
--------------------------------------------------------------------------------
/docs/devel/how-to/install-custom-path.md:
--------------------------------------------------------------------------------
1 | # How to Install Kamailio in a Custom Path
2 |
3 | Working with multiple versions could get complex unless you use
4 | different paths for installation.
5 |
6 | The command line variable PREFIX can be used to specify the root
7 | directory where all the files deployed by **make install** will be
8 | copied.
9 |
10 | Assuming you want to install version 3.3. to /usr/local/kamailio-3.3 and
11 | you checked out branch 3.3, then run following commands:
12 |
13 | make FLAVOUR=kamailio PREFIX=/usr/local/kamailio-3.3 cfg
14 | make all
15 | make install
16 |
17 | All installed files will be located in sub-folders of
18 | /usr/local/kamailio-3.3, for example:
19 |
20 | - binaries in /usr/local/kamailio-3.3/sbin
21 | - config files in /usr/local/kamailio-3.3/etc
22 |
23 | To delete this installation, simply remove /usr/local/kamailio-3.3
24 | directory.
25 |
--------------------------------------------------------------------------------
/docs/devel/how-to/internal-lib.md:
--------------------------------------------------------------------------------
1 | # How To Create And Use An Internal Library
2 |
3 | ## Create a library
4 |
5 | - make a new directory in `lib` folder
6 | - copy there the Makefile from `lib/print/` and change the name in it
7 | - add your `.c` and `.h` files.
8 |
9 | ## Use a library from a module
10 |
11 | - add to the module's Makefile (replace `print` with your lib name):
12 |
13 |
14 |
15 | SERLIBPATH=../../lib
16 | # libraries, in the format path/shortname , where shortname is
17 | # what will be used for -l
18 | SER_LIBS=$(SERLIBPATH)/print/print
19 |
20 | Compiling the module will re-compile the library automatically if needed
21 | (e.g. some change in it).
22 |
23 | `make install` will also re-link the module (needed to change the
24 | rpath).
25 |
--------------------------------------------------------------------------------
/docs/devel/how-to/main.md:
--------------------------------------------------------------------------------
1 | # Mini How-To Guides for Development
2 |
3 | This page collects a series of mini How-To guides that can be handy for
4 | new developers or people working with installations from source code.
5 |
6 | ## Table of Content
7 |
8 | - [How to Create and Use an Internal
9 | Library](internal-lib.md)
10 | - [How to Regenerate the Readme File for a
11 | Module](module-readme.md)
12 | - [How to Run Kamailio from Source Tree
13 | Directory](source-tree-run.md)
14 | - [How to Install Kamailio in a Custom
15 | Path](install-custom-path.md)
16 |
--------------------------------------------------------------------------------
/docs/devel/how-to/module-readme.md:
--------------------------------------------------------------------------------
1 | # How to Regenerate the Readme file for a Module
2 |
3 | You have to install xsltprox and XSL files for docbook.
4 |
5 | After you update the XML files from 'src/modules/modname/doc/file.xml',
6 | run the command:
7 |
8 | make modules-readme modules=src/modules/modname
9 |
10 | Examples:
11 |
12 | - regenerate the readme for modules/tm module
13 |
14 |
15 |
16 | make modules-readme modules=src/modules/tm
17 |
--------------------------------------------------------------------------------
/docs/devel/how-to/source-tree-run.md:
--------------------------------------------------------------------------------
1 | # How to Run Kamailio from Source Tree Directory
2 |
3 | As a developer (and not only), it is convenient many times to do short
4 | testing sessions without the need to completely install Kamailio.
5 |
6 | You can run it from the top directory where you keep Kamailio's source
7 | tree.
8 |
9 | Compile as usual:
10 |
11 | make FLAVOUR=kamailio cfg
12 | make all
13 |
14 | Then set **mpath** in your configuration file to be:
15 |
16 | ``` c
17 | mpath="modules_k/:modules/"
18 | ```
19 |
20 | And run Kamailio:
21 |
22 | ./kamailio -f /path/to/your/config/file
23 |
24 | Default configuration file has a define switch that allows to run from
25 | source tree directory, the command is:
26 |
27 | ./kamailio -f etc/kamailio.cfg -A WITH_SRCPATH
28 |
29 | If you want to run it in debugging mode (print logs to terminal and be
30 | verbose), you can use:
31 |
32 | ./kamailio -f etc/kamailio.cfg -A WITH_SRCPATH -E -ddd
33 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings.md:
--------------------------------------------------------------------------------
1 | # Online IRC Development Meetings
2 |
3 | IRC-based meetings hosted at:
4 |
5 | - channel: **#kamailio**
6 | - server: **irc.freenode.net**
7 |
8 | Scope:
9 |
10 | - development synchronisation
11 | - short term planning
12 |
13 | Targeted attendees:
14 |
15 | - developers
16 | - contributors
17 | - community members
18 |
19 | Access type:
20 |
21 | - free for anyone
22 |
23 | ## Meetings
24 |
25 | - [2012 - First Meeting - Tuesday, January 31, 15:00UTC](irc-meetings/2012a.md)
26 | - [2012 - Second Meeting - Thursday, November 22, 15:00UTC](irc-meetings/2012b.md)
27 | - [2013 - First Meeting - Thursday, May 16, 14:00UTC](irc-meetings/2013a.md)
28 | - [2013 - Second Meeting - Thursday, September 12, 14:00UTC](irc-meetings/2013b.md)
29 | - [2014 - First Meeting - Wednesday, May 14, 14:00UTC](irc-meetings/2014a.md)
30 | - [2015 - First Meeting - Wednesday, Feb 11, 15:00UTC](irc-meetings/2015a.md)
31 | - [2015 - Second Meeting - Wednesday, Sep 16, 14:00UTC](irc-meetings/2015b.md)
32 | - [2016 - First Meeting - Wednesday, Apr 20, 14:00UTC](irc-meetings/2016a.md)
33 | - [2016 - Second Meeting - Wednesday, Nov 09, 15:00UTC](irc-meetings/2016b.md)
34 | - [2017 - First Meeting - Thursday, Apr 20, 14:00UTC](irc-meetings/2017a.md)
35 | - [2017 - Second Meeting - Wednesday, Sep 27, 14:00UTC](irc-meetings/2017b.md)
36 | - [2018 - First Meeting - Tuesday, Jun 24, 14:00UTC](irc-meetings/2018a.md)
37 | - [2019 - First Meeting - Thursday, Feb 28, 15:00UTC](irc-meetings/2019a.md)
38 | - [2019 - Second Meeting - Thursday, Nov 14, 15:00UTC](irc-meetings/2019b.md)
39 | - [2020 - First Meeting - Wednesday, Apr 29, 14:00UTC](irc-meetings/2020a.md)
40 | - [2020 - Second Meeting - Wednesday, Nov 25, 15:00UTC](irc-meetings/2020b.md)
41 | - [2021 - First Meeting - Wednesday, Dec 15, 15:00UTC](irc-meetings/2021a.md)
42 | - [2022 - First Meeting - Thursday, Dec 08, 15:00UTC](irc-meetings/2022a.md)
43 | - [2023 - First Meeting - Tuesday, Dec 05, 14:30UTC](irc-meetings/2023a.md)
44 | - [2024 - First Meeting - Monday, Dec 09, 15:00UTC](irc-meetings/2024a.md)
45 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2013a.md:
--------------------------------------------------------------------------------
1 | # IRC Devel Meeting - 2013-05-16
2 |
3 | Date:
4 |
5 | - **Proposed: 14:00 UTC, Thursday, May 16, 2013**
6 |
7 | Time of the meeting across the world:
8 |
9 | - 16:00 - Berlin, Germany
10 | - 15:00 - London, UK
11 | - 10:00 - New York, USA
12 |
13 | Utilities:
14 |
15 | - [Time Converter](http://www.timeanddate.com/worldclock/converter.html)
16 | - IRC webchat: [http://webchat.freenode.net/](http://webchat.freenode.net/)
17 | - IRC client apps: [http://en.wikipedia.org/wiki/Internet_Relay_Chat#Clients](http://en.wikipedia.org/wiki/Internet_Relay_Chat#Clients)
18 |
19 | Place:
20 |
21 | - to be decided soon between **#kamailio** IRC channels on
22 | **irc.freenode.net** server
23 |
24 | ## Participants
25 |
26 | Participation is open to anyone, just join the IRC channel if you want
27 | to participate.
28 |
29 | People adding notes in the agenda using abbreviations:
30 |
31 | - dcm - Daniel-Constantin Mierla
32 | - pd - Peter Dunkley
33 | - osas - Ovidiu Sas
34 | - hpw - Hugh Waite
35 |
36 | ## Agenda
37 |
38 | Kamailio related:
39 |
40 | - (dcm) outstanding issues at this time, if any
41 | - (dcm) roadmap to next major release
42 | - (dcm) timeline for a new minor release
43 | - (dcm) moving compile time options to module to be able to load them
44 | at runtime
45 | - sctp module
46 | - what else?
47 | - (dcm) failure route handles on local delivery errors
48 | - execute failure routes when tcp connection is not open
49 | - (dcm) dialog vs dialog_ng
50 | - (dcm) source code tree restructuring
51 | - (pd) Outbound/GRUU - is any more development needed (in-dialog
52 | failures and single-server) (see
53 | [completing_outbound](../completing_outbound.md))
54 | - (pd) MSRP (see [completing_msrp](../completing_msrp.md))
55 | - (pd) RTCWeb Breaker (see [rtcweb_breaker](../rtcweb_breaker.md))
56 | - (pd) Presence - does anyone have the time/interest to move this
57 | forward at the moment (see
58 | [completing_presence](../completing_presence.md))
59 | - (pd) Any interest in [Amazon
60 | DynamoDB](http://aws.amazon.com/dynamodb/) support?
61 | - Amazon proprietary NoSQL database
62 | - .NET, Java, and PHP SDKs available
63 | - A bit like a managed Cassandra installation (so in theory can be
64 | used for domain, location, and subscriber tables)
65 | - (pd) event_route for TCP connection close
66 | - (osas) xhttp module
67 | - improve the API by providing a response buffer to build in http
68 | replies
69 | - improve the API to allow sending an HTTP reply in chunks
70 | - integrate xhttp with xmlrpc
71 | - (hpw) Suggested feature - debug level per module
72 | - E.g. 'debug presence 3'
73 | - Would allow debugging modules without spamming from other
74 | modules (e.g. database)
75 |
76 | ## Transcripts
77 |
78 | To be added.
79 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2013b.md:
--------------------------------------------------------------------------------
1 | # IRC Devel Meeting - 2013-09-12
2 |
3 | Date:
4 |
5 | - **Proposed: 14:00 UTC, Thursday, September 12, 2013**
6 |
7 | Time of the meeting across the world:
8 |
9 | - 16:00 - Berlin, Germany
10 | - 15:00 - London, UK
11 | - 10:00 - New York, USA
12 |
13 | Utilities:
14 |
15 | - [Time
16 | Converter](http://www.timeanddate.com/worldclock/converter.html)
17 | - IRC webchat:
18 | - IRC client apps:
19 |
20 |
21 | Place:
22 |
23 | - **#kamailio** IRC channel on **irc.freenode.net** server
24 |
25 | ## Participants
26 |
27 | Participation is open to anyone, just join the IRC channel if you want
28 | to participate.
29 |
30 | People adding notes in the agenda using abbreviations:
31 |
32 | - dcm - Daniel-Constantin Mierla
33 | - pd - Peter Dunkley
34 | - vseva - Victor Seva
35 |
36 | ## Agenda
37 |
38 | Kamailio related:
39 |
40 | - (dcm) outstanding issues at this time, if any
41 | - (dcm) roadmap to next major release
42 | - (dcm) timeline for a new minor release
43 | - (pd + others) github clone
44 | - benefits
45 | - administration
46 | - (vseva) status dealing with OpenSSL and GPL incompatibility
47 | -
48 | - ongoing work
49 | - xcap-diff - purpose and testing
50 | - dialog modules
51 | - dialog vs dialog_ng - what's the state of the second module
52 | - cleaning matching modes in dialog module
53 | - (dcm) administration
54 | - Kamailio World 2014
55 | - world wide events
56 | - admin+tech action groups for releases and maintenance
57 |
58 | ## Minutes
59 |
60 | - [2013 - Second Meeting Chat Log - Thursday, September 12,
61 | 14:00UTC](2013blog.md)
62 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2014a.md:
--------------------------------------------------------------------------------
1 | # IRC Devel Meeting - 2014-05-14
2 |
3 | Date:
4 |
5 | - **Proposed: 14:00 UTC, Wednesday, May 14, 2014** (dcm, oej, vsl)
6 | - Alternatives (add your id if you can attend)
7 | - May 16 (dcm, oej, vsl)
8 |
9 | Time of the meeting across the world:
10 |
11 | - 16:00 - Berlin, Germany
12 | - 15:00 - London, UK
13 | - 10:00 - New York, USA
14 |
15 | Utilities:
16 |
17 | - [Time
18 | Converter](http://www.timeanddate.com/worldclock/converter.html)
19 | - IRC webchat:
20 | - IRC client apps:
21 |
22 |
23 | Place:
24 |
25 | - **#kamailio** IRC channel on **irc.freenode.net** server
26 |
27 | ## Participants
28 |
29 | Participation is open to anyone, just join the IRC channel if you want
30 | to participate.
31 |
32 | People adding notes in the agenda using abbreviations:
33 |
34 | - dcm - Daniel-Constantin Mierla
35 | - vsl - Victor Seva
36 |
37 | ## Agenda
38 |
39 | Kamailio related:
40 |
41 | - (dcm) outstanding issues at this time, if any
42 | - (dcm) roadmap to next major release
43 | - (dcm) timeline for a new minor release
44 | - (dcm) status of various patches (add here if you are aware of one
45 | lost in dust)
46 | - websocket without libunistring
47 | - multipart body (vseva)
48 | - (dcm) administration
49 | - continuous integration - discussion started at KW14 (add
50 | dedicated section if you have proposals, etc.)
51 | - mirrors
52 | - world wide events
53 | - (dcm) status updates
54 | - security
55 | - IPv6
56 |
57 | ## Continuous Integration (CI)
58 |
59 | - (vsl) functional testing. Framework ??
60 |
61 | - (vsl) memory checks: ( basic functional testing needed )
62 | - valgrind
63 |
64 | - (vsl) static code analysis:
65 | - cppcheck ( jenkins jobs already there )
66 | -
67 |
68 | ## Minutes
69 |
70 | - TBA
71 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2015a.md:
--------------------------------------------------------------------------------
1 | # IRC Devel Meeting - 2015-02-11
2 |
3 | Date:
4 |
5 | - **Proposed: 15:00 UTC, Wednesday, Feb 11, 2015**
6 | - can attend: dcm, oej, vseva
7 | - Alternatives (add your id if you can attend)
8 | - Feb 12 (dcm)
9 | - Feb 17 (dcm)
10 | - 14:00 UTC (neuhaus)
11 |
12 | Time of the meeting across the world:
13 |
14 | - 16:00 - Berlin, Germany
15 | - 15:00 - London, UK
16 | - 10:00 - New York, USA
17 |
18 | Utilities:
19 |
20 | - [Time
21 | Converter](http://www.timeanddate.com/worldclock/converter.html)
22 | - IRC webchat:
23 | - IRC client apps:
24 |
25 |
26 | Place:
27 |
28 | - **#kamailio** IRC channel on **irc.freenode.net** server
29 |
30 | ## Participants
31 |
32 | Participation is open to anyone, just join the IRC channel if you want
33 | to participate.
34 |
35 | People adding notes in the agenda using abbreviations:
36 |
37 | - dcm - Daniel-Constantin Mierla
38 | - oej - Olle E. Johansson
39 | - vseva - Victor Seva
40 | - fisp - Fred Posner
41 |
42 | ## Agenda
43 |
44 | Kamailio Development:
45 |
46 | - open issues (dcm)
47 | - /tmp in defaults (vseva)
48 | - new additions (dcm)
49 | - roadmap to next major release (dcm)
50 | - more consistency on name of main c file for a module (dcm)
51 | - rename sercmd to kamcmd in the source code (dcm)
52 |
53 | Kamailio Logo:
54 |
55 | - settle on a final decision and next steps (dcm)
56 |
57 | Kamailio Administration:
58 |
59 | - RPM packaging and repositories (dcm)
60 | - backups (dcm)
61 | - unit tests (dcm)
62 | - GitHub workflow - anything to tune or improve (dcm)
63 | - a rebased pull-request looses all their comments? (vseva)
64 | - GitHub admin repo - admin/release scripts (vseva)
65 | - Security vulnerability handling (proposal below) oej
66 | - consider [RITR](https://www.bestpractical.com/rtir/)? (fisp)
67 |
68 | ------------------------------------------------------------------------
69 |
70 | ### Security Vulnerability Policy (PROPOSAL)
71 |
72 | References: \*
73 |
74 |
75 | #### Definition
76 |
77 | ???
78 |
79 | A security vulnerability is when a user of Kamailio can cause Kamailio
80 | to crash or lock up by sending messages to the server process.
81 |
82 | #### Reporting a security Vulnerability
83 |
84 | If you believe there's a security vulnerability, please don't use the
85 | public forums. Send e-mail to and the issue will
86 | be handled properly.
87 |
88 | 1. Send an e-mail to and include the following
89 | information
90 |
91 |
92 |
93 | * A summary
94 | * A detailed explanation of how this issue can be exploited and/or reproduced
95 | - A member of the Kamailio Security Team will respond
96 | - The kamailio developer team will work to solve the issue. When there is a patch for the issue, it should NOT be committed directly. It should be coordinated with the release of a security release as well as the publication of a Kamailio project security vulnerability report.
97 |
98 | #### Publishing security vulnerabilities
99 |
100 | Kamailio will publish security vulnerabilities, including an CVE ID, on
101 | the kamailio-announce mailing list, sr-users as well as related lists.
102 | The advisories will also be published on the kamailio.org web site.
103 |
104 | #### Kamailio Security Team
105 |
106 | A Kamailio Security team should be appointed with core developers of the
107 | project. These individuals will be part of the security process and
108 | review patches and text for the vulnerability report. Two persons should
109 | take the role of Kamailio Security Officers. One of these should manage
110 | each security incident - which does not mean solving the code issue, but
111 | managing the process from report to publication and patch release.
112 |
113 | ####
114 |
115 | This address should have a PGP key associated, used by the security
116 | officers.
117 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2015b.md:
--------------------------------------------------------------------------------
1 | # IRC Devel Meeting - 2015-09-16
2 |
3 | Date:
4 |
5 | - **Proposed: 14:00 UTC, Wednesday, Sep 16, 2015**
6 | - can attend: dcm vseva
7 | - Alternatives (add your id if you can attend)
8 | - Sep 17 (dcm, vseva)
9 |
10 | Time of the meeting across the world:
11 |
12 | - 16:00 - Berlin, Germany
13 | - 15:00 - London, UK
14 | - 10:00 - New York, USA
15 |
16 | Utilities:
17 |
18 | - [Time
19 | Converter](http://www.timeanddate.com/worldclock/converter.html)
20 | - IRC webchat:
21 | - IRC client apps:
22 |
23 |
24 | Place:
25 |
26 | - **#kamailio** IRC channel on **irc.freenode.net** server
27 |
28 | ## Participants
29 |
30 | Participation is open to anyone, just join the IRC channel if you want
31 | to participate.
32 |
33 | People adding notes in the agenda using abbreviations:
34 |
35 | - dcm - Daniel-Constantin Mierla
36 | - vseva - Victor Seva
37 | - co - Camille Oudot (14:00 to 14:30 UTC only)
38 | - hpw - Hugh Waite
39 |
40 | ## Agenda
41 |
42 | Kamailio Development:
43 |
44 | - open issues (dcm)
45 | - new additions (dcm)
46 | - what is expected from devs and broad community
47 | - roadmap to next major release (dcm)
48 | - when it should happen
49 | - suggestion: $time() and $timef() return local time, add another that
50 | returns UTC? (hpw)
51 |
52 | Kamailio Administration:
53 |
54 | - RPM packaging and repositories (dcm)
55 | - DEB packaging (vseva)
56 | - backups (dcm)
57 | - unit tests (dcm)
58 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2016a.md:
--------------------------------------------------------------------------------
1 | # IRC Devel Meeting - 2016-04-21
2 |
3 | Date:
4 |
5 | - **Proposed: 14:00 UTC, Thursday, Apr 21, 2016**
6 | - can attend: dcm, oej, tuxd00d, abalashov, vseva, qxork
7 | - Alternatives (add your id if you can attend)
8 | - Apr 20: dcm, tuxd00d, abalashov, vseva, qxork
9 | - cannot attend: oej
10 |
11 | Time of the meeting across the world:
12 |
13 | - 16:00 - Berlin, Germany
14 | - 15:00 - London, UK
15 | - 10:00 - New York, USA
16 |
17 | Utilities:
18 |
19 | - [Time Converter](http://www.timeanddate.com/worldclock/converter.html)
20 | - IRC webchat: [http://webchat.freenode.net/](http://webchat.freenode.net/)
21 | - IRC client apps: [http://en.wikipedia.org/wiki/Internet_Relay_Chat#Clients](http://en.wikipedia.org/wiki/Internet_Relay_Chat#Clients)
22 |
23 | Place:
24 |
25 | - **#kamailio** IRC channel on **irc.freenode.net** server
26 |
27 | ## Participants
28 |
29 | Participation is open to anyone, just join the IRC channel if you want
30 | to participate.
31 |
32 | People adding notes in the agenda using abbreviations:
33 |
34 | - dcm - Daniel-Constantin Mierla
35 | - vseva - Victor Seva (linuxmaniac)
36 |
37 | ## Agenda
38 |
39 | Kamailio Development Status:
40 |
41 | - open issues (dcm)
42 | - rpc response without data (sr-users:
43 | [http://lists.sip-router.org/pipermail/sr-users/2016-April/092510.html](http://lists.sip-router.org/pipermail/sr-users/2016-April/092510.html))
44 | - rpm packaging (dcm)
45 |
46 | Administration:
47 |
48 | - servers maintenance
49 | - shared repository or tools to generate some of the static content
50 | (e.g., docs index)
51 | - community interaction and communication channels
52 |
53 | Kamailio 5.0
54 |
55 | - [https://www.kamailio.org/wiki/devel/kamailio-5.0-design](https://www.kamailio.org/wiki/devel/kamailio-5.0-design)
56 | - source code tree restructuring (dcm)
57 | - config file routing logic in embedded language (dcm)
58 | - support DB schema backwards compatibility (vseva)
59 | - [http://lists.sip-router.org/pipermail/sr-users/2016-April/092619.html](http://lists.sip-router.org/pipermail/sr-users/2016-April/092619.html)
60 | - unit tests (dcm)
61 | - build system review (dcm)
62 | - roadmap/timelines to next major release (dcm)
63 |
64 | Meeting for Designing, Coding and Tuning Kamailio 5.0
65 |
66 | - yes/no?
67 | - who?
68 | - where?
69 | - when?
70 |
71 | ## Minutes
72 |
73 | - [Minutes Page](2016a-minutes.md)
74 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2017a.md:
--------------------------------------------------------------------------------
1 | # IRC Devel Meeting - 2017-04-20
2 |
3 | Date:
4 |
5 | - **Proposed: 14:00 UTC, Thursday, Apr 20, 2017**
6 | - can attend: dcm vseva qxork
7 | - cannot attend:
8 | - Alternatives (add your id if you can attend)
9 | - Apr 24: dcm vseva qxork
10 | - Apr 25: dcm vseva qxork
11 |
12 | Time of the meeting across the world:
13 |
14 | - 16:00 - Berlin, Germany
15 | - 15:00 - London, UK
16 | - 10:00 - New York, USA
17 |
18 | Utilities:
19 |
20 | - [Time
21 | Converter](http://www.timeanddate.com/worldclock/converter.html)
22 | - IRC webchat:
23 | - IRC client apps:
24 |
25 |
26 | Place:
27 |
28 | - **#kamailio** IRC channel on **irc.freenode.net** server
29 |
30 | ## Participants
31 |
32 | Participation is open to anyone, just join the IRC channel if you want
33 | to participate.
34 |
35 | People adding notes in the agenda using abbreviations:
36 |
37 | - dcm - Daniel-Constantin Mierla
38 | - qxork - Fred Posner
39 |
40 | ## Agenda
41 |
42 | Kamailio Development Status:
43 |
44 | - open issues (dcm)
45 | - minor releases for 4.3, 4.4 and 5.0 branches (dcm)
46 |
47 | Administration:
48 |
49 | - servers maintenance
50 | - community interaction and communication channels
51 | - existing mailing lists review -- some old one were just revived, but
52 | do they worth keeping?
53 |
54 | Kamailio 5.1 (next major release):
55 |
56 | - roadmap
57 | - features
58 | - anything relevant that is missing?
59 | - priorities
60 |
61 | Documentation:
62 |
63 | - tutorials/cookbooks -- wiki vs mkdocs (github markdown)
64 |
65 | Collaborative Projects:
66 |
67 | - unit testing, documentation, etc.
68 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/2019b.md:
--------------------------------------------------------------------------------
1 | # Online IRC Devel Meeting - 2019-03-11
2 |
3 | This online meeting is planned to be done via WebRTC video conferencing
4 | bridge, with IRC channel used only when some written chat is needed.
5 | Details of the video conference bridge will be posted shortly before the
6 | meeting starts.
7 |
8 | Date:
9 |
10 | - **Proposed: 15:00 UTC, Thursday, Nov 15, 2019**
11 | - can attend: dcm, ...
12 | - cannot attend:
13 |
14 | Time of the meeting across the world:
15 |
16 | - 16:00 - Berlin, Germany
17 | - 15:00 - London, UK
18 | - 10:00 - New York, USA
19 | - 07:00 - Seattle, USA
20 |
21 | Utilities:
22 |
23 | - [Time
24 | Converter](http://www.timeanddate.com/worldclock/converter.html)
25 | - IRC webchat:
26 | - IRC client apps:
27 |
28 |
29 | Place:
30 |
31 | - Video conference bridge: TBA
32 | - **#kamailio** IRC channel on **irc.freenode.net** server
33 |
34 | ## Participants
35 |
36 | Participation is open to anyone, just join the Video bridge/IRC channel
37 | if you want to participate.
38 |
39 | People adding notes in the agenda using abbreviations:
40 |
41 | - dcm - Daniel-Constantin Mierla
42 | - vseva - Victor Seva
43 |
44 | ## Agenda
45 |
46 | Kamailio Development Status:
47 |
48 | - open issues (dcm)
49 | - minor releases for 5.2 and 5.3 branches (dcm)
50 | - end of maintenance for 5.1 branch
51 |
52 | Administration:
53 |
54 | - servers maintenance
55 | - community interaction and communication channels
56 | - existing mailing lists review
57 |
58 | Kamailio 5.4 (next major release):
59 |
60 | - roadmap
61 | - features
62 | - anything relevant that is missing?
63 | - priorities
64 | - packaging rtpengine on deb.kamailio.org and rpms ..
65 |
66 | Documentation:
67 |
68 | - tutorials/cookbooks -- wiki vs mkdocs (github markdown)
69 |
70 | Collaborative Projects:
71 |
72 | - development, unit testing, documentation, etc.
73 |
74 | ## Transcript of Meeting
75 |
76 | ### 1. Summary of development meeting so far
77 |
78 | #### 1.1 Kamailio release process
79 |
80 | - Kamailio release 5.3.1 today
81 | - Notes taken, future automatisation and template creation
82 | - Daniel will continue with 5.3.x releases, 5.2.x releases will be
83 | done from Henning
84 |
85 | #### 1.2 Documentation work
86 |
87 | - Olle and other developers investigated the current situation of
88 | documentation
89 | - it is sometimes confusing for new people
90 | - goals formulated to improve situation in the future
91 |
92 | #### 1.3 Architecture for future message/event passing
93 |
94 | - current multi-process architecture makes some operations difficult
95 | - to be discussed more in the future
96 |
97 | #### 1.4 RPM repository
98 |
99 | - Sergey and Giacomo investigated new RPM repository
100 | - if new Hardware is needed, Fred could help here
101 | - use an existing cloud service to build RPMs
102 |
103 | #### 1.5. Module status
104 |
105 | - discussion about module status, like commit frequency
106 | - separation of repositories
107 | - duplication of modules fine in Kamailio
108 | - no clear policy decided, but main problem regarding support status
109 | open
110 |
111 | ### 2.0 Kamailio 5.4.0 and 6.0
112 |
113 | #### 2.1 General topics
114 |
115 | - proposed date in Summer 2020 for 5.4.0
116 | - last maintenance for 5.1.x branch, end of life
117 | - release policies (long term releases) discussed - no big changes
118 | necessary
119 | - clarification on release policy on the web benefitial
120 |
121 | #### 2.2 core architecture extensions
122 |
123 | - discussion about future message/event passing
124 | - Kamailio 6.0 new architecture
125 | - clustering, database and network socket extensions
126 |
127 | #### 2.4 tools discussion
128 |
129 | - kamcmd vs. kamctl vs. kamcli
130 | - different tools for different use cases
131 | - unification necessary
132 | - deprecation warning to be added
133 |
134 | ### 3.0 infrastructure topics
135 |
136 | #### 3.1 server maintenance
137 |
138 | - Debian OS level fine at the moment
139 | - ansible/puppet experiments from Victor
140 | - to be decided if its ansible or puppet
141 |
142 | #### Slack, Matrix etc..
143 |
144 | - IRC channel has less activity now after requirement of login
145 | - Slack channel has some activitity now, but is proprietary
146 | - Matrix channel discussion for kamailio
147 | - at the moment more than 500 people on sr-dev, over 2000 people on
148 | sr-users
149 | - discussion synchron vs. async communication modes
150 | - good quality of mailing lists, professional communication
151 |
152 | ####
153 |
154 | - current web page a bit cluttered, needs some cleanup
155 | - discussions for re-design on the meeting
156 |
--------------------------------------------------------------------------------
/docs/devel/irc-meetings/securityprocedure.md:
--------------------------------------------------------------------------------
1 | # Security Vulnerability Policy (PROPOSAL)
2 |
3 | References: \*
4 |
5 |
6 | ## Definition
7 |
8 | ???
9 |
10 | A security vulnerability is when a user of Kamailio can cause Kamailio
11 | to crash or lock up by sending messages to the server process.
12 |
13 | ## Reporting a security Vulnerability
14 |
15 | If you believe there's a security vulnerability, please don't use the
16 | public forums. Send e-mail to and the issue will
17 | be handled properly.
18 |
19 | 1. Send an e-mail to and include the following
20 | information
21 |
22 |
23 |
24 | * A summary
25 | * A detailed explanation of how this issue can be exploited and/or reproduced
26 | - A member of the Kamailio Security Team will respond
27 | - The kamailio developer team will work to solve the issue. When there is a patch for the issue, it should NOT be committed directly. It should be coordinated with the release of a security release as well as the publication of a Kamailio project security vulnerability report.
28 |
29 | ## Publishing security vulnerabilities
30 |
31 | Kamailio will publish security vulnerabilities, including an CVE ID, on
32 | the kamailio-announce mailing list, sr-users as well as related lists.
33 |
34 | ## Kamailio Security Team
35 |
36 | A Kamailio Security team should be appointed with core developers of the
37 | project. These individuals will be part of the security process and
38 | review patches and text for the vulnerability report. Two persons should
39 | take the role of Kamailio Security Officers. One of these should manage
40 | each security incident - which does not mean solving the code issue, but
41 | managing the process from report to publication and patch release.
42 |
43 | ##
44 |
45 | This address should have a PGP key associated, used by the security
46 | officers.
47 |
--------------------------------------------------------------------------------
/docs/devel/kamailio-5.0-design.md:
--------------------------------------------------------------------------------
1 | # Kamailio v5.0 Design
2 |
3 | ## Overview
4 |
5 | After 15 years of development, it is time for Kamailio v5.0.
6 |
7 | This page collects suggestions and ideas for major refactoring of
8 | various components to make the leap to v5.0.
9 |
10 | When adding a remark that needs to be tracked by author, use initials in
11 | front of the paragraph. The list of contributors to this document and
12 | initials:
13 |
14 | - Daniel-Constantin Mierla (dcm)
15 |
16 | ## Initial Remarks
17 |
18 | Initial content for this document is listing also ideas popped up during
19 | discussions at Fosdem 2016 and Kamailio Development Workshop - among
20 | participants: Camille Oudout, Daniel-Constantin Mierla, Federico
21 | Cabiddu, Giacomo Vacca, Henning Westerholt, Olle E. Johansson, Torrey
22 | Searle, Victor Seva.
23 |
24 | ## Configuration File Interpreters
25 |
26 | Goals:
27 |
28 | - have at least one option of an optimized configuration file
29 | interpreter targeting high performance SIP routing deployments
30 | - have at least one option of a more flexible configuration language
31 | that allows:
32 | - extended language syntax
33 | - reloading routing rules at runtime
34 |
35 | Ongoing implementation that enables writing routing blocks in Lua and
36 | Python as alternative to native language is documented at:
37 |
38 | - [Configuration File Engines](../devel/config-engines.md)
39 |
40 | ## Source Tree Structure
41 |
42 | Goals:
43 |
44 | - group files per components to be easier to spot their role,
45 | especially the core, include files and utilities
46 |
47 | ### Reorganizing Source Files Location
48 |
49 | It was discussed in the past:
50 |
51 | - source code files should be relocated to have a better structure for
52 | include headers, core files, modules and internal libraries as well
53 | as utilities
54 |
55 | Two models proposed:
56 |
57 | - a\) only move core files in a new 'core' folder in the root
58 | directory
59 | - b\) move all source code files for Kamailio in a new 'src' folder,
60 | with further re-organization with subfolders inside 'src'
61 |
62 | ## Build System
63 |
64 | Goals:
65 |
66 | - revising the build system based on Makefiles.
67 |
68 | ### Reviewing Alternative Build Systems
69 |
70 | Alternatives to analyze:
71 |
72 | - configure
73 | - cmake
74 |
75 | ## Continuous Integration
76 |
77 | Goals:
78 |
79 | - attempt to make a more consistent and "easy to contribute to"
80 | continuous integration eco-system
81 |
82 | ### Unit Test Framework
83 |
84 | Reviving the exiting unit testing or selecting another framework.
85 |
86 | Available frameworks:
87 |
88 | - (python)
89 |
90 | ### Minimal Unit Tests
91 |
92 | Defining a minimum set of automatic tests that needs to be provided by
93 | each module:
94 |
95 | - a minimal config for loading the module, to be sure it doesn't have
96 | missing linking symbols
97 | - can be done with a config as simple as:
98 |
99 |
100 |
101 | loadmodule "foo.so"
102 |
103 | request_route {
104 | ;
105 | }
106 |
107 | - or can require setting some module parameters or even loading other
108 | modules
109 |
--------------------------------------------------------------------------------
/docs/devel/libcurl_integration.md:
--------------------------------------------------------------------------------
1 | # libcurl integration
2 |
3 | This page is a place to discuss the integration of libcurl into
4 | Kamailio.
5 |
6 | There are currently five modules that use the curl library:
7 |
8 | - utils
9 | - xcap_client
10 | - auth_identity
11 | - curl
12 | - async_http (currently on a pull-request)
13 |
14 | ### Reason for integration
15 |
16 | libcurl and some libraries that it uses (openSSL) can conflict if
17 | initialised multiple times. If users wish to use more than one feature
18 | that depends on libcurl, the conflict must be resolved. This is likely
19 | to be achieved by having a single module that wrappers libcurl and is
20 | responsible for global initialisation etc. The different ways it can be
21 | called can be exported by APIs to other modules.
22 |
23 | ### Requirements
24 |
25 | - Synchronous queries
26 | - Asynchronous queries that suspend the transaction and resume on
27 | completion
28 | - Asynchronous queries that call an event_route on completion
29 | - Ability to configure 'named connections' with preset curl options
30 | (keys/certs, verify flags etc)
31 | - query functions exported via a C API to other modules
32 |
33 | Any more? See also
34 | [TODO.txt](https://github.com/kamailio/kamailio/blob/master/modules/curl/todo.txt)
35 | in the curl module
36 |
37 | - Ability to pass a list of HTTP header to add
38 | - Ability to retrieve response headers (e.g. header callback
39 | function) - required for xcap_client module
40 |
41 | ### Discussion
42 |
43 | The curl module currently offers a synchronous query function which can
44 | use named connections set up in modparams. Client certificates and
45 | parameters can be configured globally or per connection and there is an
46 | exported API. This uses the curl 'easy' interface without worker
47 | processes.
48 |
49 | The async_http module offers an asynchronous query function which can
50 | optionally suspend the transaction. This uses the curl 'multi' interface
51 | and creates worker processes.
52 |
53 | The final solution will be a combination of these, however consensus
54 | should be reached on the architecture. Should these be combined into a
55 | single module, or should one depend on the other? It should of course be
56 | easy to understand by the end user.
57 |
58 | Items to discuss:
59 |
60 | - Name of modules(s)
61 | - Definition of API functions and parameters
62 | - Use of worker pools
63 |
64 | Names
65 |
66 | - The curl module has been renamed to "Http_client"
67 | - Need new name for the new module
68 |
69 | Please add your own comments below (hpw)
70 |
71 | - (gv) I think it was mentioned at the meeting in Brussels: it would
72 | be nice to have a separate configuration file with the
73 | "connections", which can be reloaded at run time (like
74 | ).
75 | - (oej) The "curl" prefix needs to go away from the functions,
76 | parameters and api in the http_client module. New names discussed on
77 | sr-dev
78 |
--------------------------------------------------------------------------------
/docs/devel/makefile-system.md:
--------------------------------------------------------------------------------
1 | # Kamailio's Makefile System
2 |
3 | ## Generate Main Binary
4 |
5 | make
6 |
7 | ## Compile Everything
8 |
9 | make all
10 |
11 | ## Install Everything
12 |
13 | make install
14 |
15 | ## Clean Source Tree
16 |
17 | - clean object files
18 |
19 |
20 |
21 | make clean
22 |
23 | - clean all generated files
24 |
25 |
26 |
27 | make proper
28 |
29 | ## Generate Modules
30 |
31 | make modules
32 |
33 | ## Generate Config for Makefile
34 |
35 | make cfg
36 |
37 | - add extra defines in makefile config
38 |
39 |
40 |
41 | make EXTRA_DEFS="-DSTATISTICS" cfg
42 |
43 | - cfg for Makefile is config.mak
44 | - you can edit it and tune as you wish before compilation
45 |
46 | ## Enable Module
47 |
48 | If the module is not compiled by default:
49 |
50 | - edit **modules.lst**
51 | - remove the name of the module from **exclude_modules** variable
52 |
53 | or type: `make modules-cfg include_modules=` .
54 |
55 | The same can be accomplished with
56 | `make cfg include_modules= ` , but this will remake
57 | the whole config.
58 |
59 | ## Combined Parameters
60 |
61 | Various parameters can be given to make command, an example:
62 |
63 | ``` c
64 | make prefix=/opt/kamailio \
65 | SCTP=1 \
66 | CC_EXTRA_OPTS=-I/usr/gnu/include \
67 | group_include="standard postgres presence" \
68 | include_modules="snmpstats perl tls" \
69 | all
70 |
71 | ```
72 |
73 | or you can save them in the config (they will be used by future make
74 | invocations) by givin the same parameters to make cfg:
75 |
76 | ``` c
77 | make cfg prefix=/opt/kamailio \
78 | SCTP=1 \
79 | CC_EXTRA_OPTS=-I/usr/gnu/include \
80 | group_include="standard postgres presence" \
81 | include_modules="snmpstats lcr tls"
82 | ```
83 |
84 | ## Generate README For Modules
85 |
86 | - all READMEs for modules located in directory **modules**
87 |
88 |
89 |
90 | make modules-readme
91 |
92 | - README for one module. Example for **modules/dispatcher**:
93 |
94 |
95 |
96 | make modules-readme modules=modules/dispatcher
97 |
98 | or
99 |
100 | make -C modules/dispatcher/doc readme
101 |
102 | ## Generate Different Formats For Modules Documentation
103 |
104 | Available formats: \* txt - text plain \* xhtml - single xhtml file \*
105 | html - html files (chunks) split by sections \* pdf - PDF file
106 |
107 | Command to generate a specific format for a module:
108 |
109 | make modules-doc doc_format=format modules=path/to/module
110 |
111 | Example: generate single xhtml file for **auth** module:
112 |
113 | make modules-doc doc_format=xhtml modules=modules/auth
114 |
115 | ## Regenerated Database Scripts
116 |
117 | make dbschema
118 |
119 | ## Various Helpful Commands
120 |
121 | ### Print Uninstall Details
122 |
123 | make uninstall
124 |
125 | ### Install Debian init.d Scripts
126 |
127 | make install-initd-debian
128 |
129 | ### Install CentOS init.d Scripts
130 |
131 | make install-initd-centos
132 |
133 | ### Print C Define Flags
134 |
135 | make printcdefs
136 |
137 | ### Print Content of Variable
138 |
139 | make printvar v=varname
140 |
141 | Printing $(C_DEFS) content.
142 |
143 | make printvar v=C_DEFS
144 |
--------------------------------------------------------------------------------
/docs/devel/module-docbook-readme.md:
--------------------------------------------------------------------------------
1 | # Writing Docbook Files for Module Readme
2 |
3 | README file for each module is generated from xml docbook files residing
4 | in **doc/** sub folder. The README file must not be changed directly,
5 | the editing has to be done to the xml docbook files.
6 |
7 | When one adds a new module it has to write these xml docbook files and
8 | then generate the first version of README using:
9 |
10 | make modules-readme modules=modules/modname
11 |
12 | For old modules (or after the new module has been published to the
13 | public git repository) do not generate anymore the README for pushing it
14 | to git. Push only the changes to the xml files, because the README will
15 | be automatically generated by a cron service running on server to ensure
16 | coherent formatting and avoid conflicts when having to backport to older
17 | branches.
18 |
19 | Of course, you can generate the README locally to check if the result is
20 | the expected one, but then restore the old README without changes -- it
21 | can be done with:
22 |
23 | rm src/modules/modname/README
24 | git checkout src/modules/modname/README
25 |
26 | ## Naming Files
27 |
28 | ### Kamailio Style
29 |
30 | The docbook file are:
31 |
32 | - modname.xml (e.g., acc.xml) - the main docbook file, including other
33 | files that have content
34 | - modname_admin.xml (e.g., acc_admin.xml) - the docbook file that
35 | includes content targeting administrators (e.g., short description,
36 | dependencies, parameters and functions for the config file, a.s.o.)
37 | - modname_devel.xml - the docbook file that includes content targeting
38 | developers (e.g., inter module APIs)
39 |
40 | ### SER Style
41 |
42 | The docbook file are:
43 |
44 | - modname.xml - the main docbook file, including other files that have
45 | content
46 | - params.xml - the docbook file that includes module config parameters
47 | - funcs.xml - the docbook file that includes module config functions
48 | - ...
49 |
50 | ## Section IDs
51 |
52 | To generate IDs that make html version of README easier to refer to,
53 | each section tag for parameters, functions, etc. has to contain an
54 | **id** attribute. To avoid conflicts when merging some readme file, the
55 | value of ID attributes should use following pattern:
56 |
57 | [module name] [dot] [type] [dot] [title]
58 |
59 | The \[type\] should be:
60 |
61 | - p - parameters
62 | - f - functions
63 | - m - mi commands
64 | - r - rpc commands
65 | - s - statistics
66 | - e - event routes
67 | - v - pseudovariable
68 |
69 | Next is an example showing the id for the section corresponding to
70 | parameter **workers** from module **async**:
71 |
72 |
73 | workers (int)
74 |
--------------------------------------------------------------------------------
/docs/devel/new-features-requests.md:
--------------------------------------------------------------------------------
1 | # New Features Requests
2 |
3 | This page collects the requests of new features that are not an
4 | immediate priority for Kamailio project.
5 |
6 | ## GNUTLS Module
7 |
8 | Add a new module to offer SIP over TLS using GNUTLS library as an
9 | alternative to existing TLS module which relies on LIBSSL.
10 |
11 | -
12 |
13 | ## LIBRESSL Module
14 |
15 | Add a new module to offer SIP over TLS using LibreSSL library as an
16 | alternative to existing TLS module. LibreSSL is TLS lib for OpenBSD
17 | dist.
18 |
19 | -
20 |
--------------------------------------------------------------------------------
/docs/devel/rtcweb_breaker.md:
--------------------------------------------------------------------------------
1 | # Introduction
2 |
3 | The [Doubango Telecom](http://www.doubango.org)
4 | [webrtc2sip](http://webrtc2sip.org/) gateway includes an RTCWeb Breaker
5 | component. The Doubango RTCWeb Breaker is a B2BUA. It would be useful to
6 | have a Kamailio RTCWeb Breaker that is lighter-weight and which can be
7 | used without degrading the SIP signalling by using a B2BUA.
8 |
9 | An RTCWeb Breaker converts SDP and media streams between those supported
10 | by WebRTC end-points and non-WebRTC end-points. An RTCWeb Breaker does
11 | not need to transcode the media streams; G.711 is supported by most SIP
12 | UAs and is a Mandatory To Implement (MTI) codec in WebRTC, and many SIP
13 | UAs now support OPUS and VP8 too.
14 |
15 | ## Proposed RTCWeb Breaker architecture
16 |
17 | The RTCWeb Breaker should consist of two components:
18 |
19 | - A Kamailio control module
20 | - An RTCWeb Breaker daemon
21 |
22 | Kamailio should control the RTCWeb Breaker using a light-weight TCP
23 | protocol. SDP should be handled and manipulated by the RTCWeb daemon.
24 |
25 | RTCWeb Breaker sessions should be initiated within Kamailio failure
26 | routes and branch-failure routes. In parallel forking scenarios Kamailio
27 | should create distinct RTCWeb Breaker sessions in branch-failure routes
28 | enabling sessions to be successfully forked to WebRTC and non-WebRTC
29 | end-points.
30 |
31 | 
32 |
33 | ## Example RTCWeb Breaker signalling flow
34 |
35 | 
36 |
37 | ## Scenarios
38 |
39 | The RTCWeb Breaker SHOULD support:
40 |
41 | - Sessions from WebRTC to non-WebRTC end-points
42 | - Sessions from non-WebRTC to WebRTC end-points
43 | - Session renegotiation using re-INVITE and UPDATE
44 | - Early media (SDP in 183, PRACK, and UPDATE)
45 | - SDP offer in INVITE and answer in 180/183/200
46 | - SDP offer in 180/183/200 and answer in ACK
47 | - Parallel forking (distinct RTCWeb Breaker sessions for each branch
48 | that requires it)
49 |
--------------------------------------------------------------------------------
/docs/devel/rtpproxy-ng.md:
--------------------------------------------------------------------------------
1 | # RTPProxy-NG
2 |
3 | This page is intended to collate suggestions for improvements and new
4 | features for RTPProxy and the Kamailio RTPProxy module.
5 |
6 | ### Architecture
7 |
8 | #### JSON Interface
9 |
10 | - Will make the interface simpler and easier to extend.
11 |
12 | #### Send/receive SDP to/from RTPProxy
13 |
14 | - Enables the RTPProxy to see and directly manipulate the SDP.
15 |
16 | ### Kamailio RTPProxy Module
17 |
18 | #### re-INVITE/UPDATE failure handling
19 |
20 | - When a re-INVITE/UPDATE fails the original stream should be used.
21 | - Currently, the module closes the old stream.
22 | - Also may cause problems with early media where early stream and
23 | active stream are connected to different end-points.
24 |
25 | #### Hangs during startup when RTPProxy instance is unavailable
26 |
27 | - Each RTPProxy instance is contacted in-sequence. If one or more
28 | RTPProxy instances is unavailable Kamailio hangs until the connect
29 | attempt times out.
30 | - RTPProxy connection at start-up should be asynchronous.
31 |
32 | #### Enable/disable and add/remove RTPProxy instances
33 |
34 | - Would be good to load sets from a DB.
35 | - DB should contain indications whether RTPProxy is enabled/disabled
36 | at load.
37 | - Reload DB to change RTPProxy sets (and enable/disable proxies within
38 | sets) - probably needs hash-table data-structure changes.
39 | - Be able to mark RTPProxies enabled/disabled through MI command.
40 | Existing calls (and re-INVITE/UPDATE) on disabled proxies should
41 | continue to work, but new calls should not go to a disabled proxy.
42 |
43 | #### Receive RTP timeout notifications
44 |
45 | - rtpproxies should be able to notify, via the new rtpproxy protocol,
46 | media timeouts to the corresponding Kamailio instance (to the
47 | rtpproxy module).
48 | - The rtpproxy module should be able to trigger some event route in
49 | which the user could decide to send a BYE in both directions, stop
50 | the accounting or whatever. No more HTTP XMLRPC for notifying
51 | timeouts to a single Kamailio server (hack).
52 |
53 | ### RTPProxy
54 |
55 | #### ICE Support
56 |
57 | - TURN Server as well as RTPProxy
58 | - Handle ICE candidate lines in SDP
59 | - Breaking ICE (for CALEA and call recording)
60 | - Architecture, SDP sent to/from RTPProxy (from above) will be
61 | required
62 |
63 | #### Bridging
64 |
65 | - Currently can only specify two networks
66 | - Would be good to be able to specify many networks and bridge between
67 | any combination
68 |
69 | #### Failover
70 |
71 | - Deploy RTPProxies in pairs, replicate media sessions between them,
72 | fail-over/swap between instances.
73 |
74 | #### RTP timeout notification
75 |
76 | - If a media sessions timeouts (so rtpproxy closes its sockets)
77 | rtpproxy should notify it to the proper Kamailio instance by
78 | providing data enough to Kamailio about the session (call-id, from,
79 | to...).
80 |
81 | #### RTP/AVP to RTP/SAVPF conversion
82 |
83 | - For WebRTC
84 | - Need to be able to decrypt traffic from WebRTC and encrypt traffic
85 | to WebRTC
86 | - Need to be able to terminate and originate RTCP messages for the
87 | stream from/to WebRTC (if the other side does not support WebRTC)
88 | - ICE support (above) will be required
89 |
90 | #### SRTP-RTP Gatewaying
91 |
92 | - Works only if RTPProxy sees the session key (e.g. SDES: RFC 4568)
93 |
94 | #### Session Statistics
95 |
96 | - The current statistics give little information about the media
97 | session. The most obvious missing informations is the codec used
98 | during the session.
99 |
--------------------------------------------------------------------------------
/docs/devel/troubleshooting-gdb-scripts.md:
--------------------------------------------------------------------------------
1 | # Troubleshooting - GDB Snippets
2 |
3 | A collection of GDB scripts useful to print Kamailio's internals at
4 | runtime.
5 |
6 | ## TM Module
7 |
8 | ### Transaction Structures
9 |
10 | Transactions are stored in hash table \_tm_table that has 65536 slots
11 | (defined as TABLE_ENTRIES in the code).
12 |
13 | ``` perl
14 | set $i=0
15 | while($i<65536)
16 |
17 | set $ehead = &_tm_table->entries[$i]
18 | set $tcell = _tm_table->entries[$i].next_c
19 |
20 | while($ehead!=(void*)$tcell)
21 | p $tcell
22 | p *$tcell
23 | set $tcell = $tcell->next_c;
24 | end
25 |
26 | set $i = $i + 1
27 | end
28 | ```
29 |
30 | ## Memory
31 |
32 | See:
33 |
34 | -
35 |
--------------------------------------------------------------------------------
/docs/devel/update-database-schema.md:
--------------------------------------------------------------------------------
1 | # Update Database Schema
2 |
3 | Kamailio's database schema is specified in an XML format, which allows
4 | generation of creation scripts for many database types at once.
5 |
6 | The XML files with the database table definitions are located in the
7 | source tree, inside subdirectory:
8 |
9 | lib/srdb1/schema/
10 |
11 | Each table is defined in the file tablename.xml. For example, the
12 | definition of table domain is in file:
13 |
14 | lib/srdb1/schema/domain.xml
15 |
16 | Changing the database schema (adding new tables,
17 | adding/removing/updating columns) must be done creating or updating the
18 | XML files.
19 |
20 | Regeneration of the database creation scripts is done running the next
21 | command inside the root folder of the source tree:
22 |
23 | make dbschema
24 |
25 | This command generates the SQL or control files to be used by kamdbctl
26 | tool when creating the database structure. It requires the tool
27 | **xsltproc** to process the XML files, tool which is also needed for
28 | generation of the readme files. The sql scripts will be placed in
29 | subfolders of 'utils/kamctl/'
30 |
31 | Changing the structure of an existing database table requires only the
32 | above steps. Adding a new table requires as well:
33 |
34 | - adding the table to be part of a specific group of tables. If the
35 | table is used by a module that uses other tables, all of them have
36 | to be in the same group. Tables group definitions are stored in the
37 | files kamailio-groupname.xml . It is common to use the module name
38 | as the group name.
39 | - adding the table to kamctl and kamdbctl tools for creation
40 |
41 | For example, the group of the tables used by module domain, domain and
42 | domain_attrs, is specified in file:
43 |
44 | lib/srdb1/schema/kamailio-domain.xml
45 |
46 | To generate the documentation of the existing kamailio-db-devel tables:
47 |
48 | cd lib/srdb1/schema; make docbook-xml
49 | cd doc/databases/kamailio; make html
50 | firefox tables.html
51 |
52 | If you add a new table, you must add the new files related to it to GIT
53 | repository, before committing the changes. It is recommended to split
54 | the commit in two parts, because they affect different components:
55 |
56 | - one for the XML files (they are part of internal library srdb1)
57 | - one for DB creation scripts (they are part of kamctl tool)
58 |
59 | This brings the benefit of easy backporting, because the commit to xml
60 | file is unlikely to create conflicts, changing one file in a group of
61 | lines related to same column, so it can be cherry-picked alone. Commits
62 | to database creation scripts affects many files and can result in
63 | conflicts if new columns were added meanwhile to the development version
64 | to that table.
65 |
66 | If there is a fix that has to be backported, always do it to master
67 | branch and then cherry-pick it in the stable branches. With split
68 | commits, the typical backport procedure is:
69 |
70 | - cherry-pick only the commit to xml files
71 | - regenerated the schema for the stable branch and commit the updates
72 |
--------------------------------------------------------------------------------
/docs/download/v3.2.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v3.2.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 3.2 (release series v3.2.x) and Kamailio flavour.
5 |
6 | ## Kamailio v3.2.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v3.2.x.
9 |
10 | git clone --depth 1 git://git.sip-router.org/sip-router kamailio
11 | cd kamailio
12 | git checkout -b 3.2 origin/3.2
13 | make FLAVOUR=kamailio cfg
14 |
--------------------------------------------------------------------------------
/docs/download/v3.3.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v3.3.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 3.3 (release series v3.3.x) and Kamailio flavour.
5 |
6 | ## Kamailio v3.3.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v3.3.x.
9 |
10 | git clone --depth 1 git://git.sip-router.org/sip-router kamailio
11 | cd kamailio
12 | git checkout -b 3.3 origin/3.3
13 | make FLAVOUR=kamailio cfg
14 |
--------------------------------------------------------------------------------
/docs/download/v4.0.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v4.0.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 4.0 (release series v4.0.x).
5 |
6 | ## Kamailio v4.0.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v4.0.x.
9 |
10 | git clone --depth 1 git://git.sip-router.org/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 4.0 origin/4.0
13 |
--------------------------------------------------------------------------------
/docs/download/v4.1.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v4.1.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 4.1 (release series v4.1.x).
5 |
6 | ## Kamailio v4.1.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v4.1.x.
9 |
10 | git clone --depth 1 git://git.sip-router.org/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 4.1 origin/4.1
13 |
--------------------------------------------------------------------------------
/docs/download/v4.2.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v4.2.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 4.2 (release series v4.2.x).
5 |
6 | ## Kamailio v4.2.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v4.2.x.
9 |
10 | git clone --depth --no-single-branch 1 git://git.sip-router.org/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 4.2 origin/4.2
13 |
14 | *Note: if your git client version does not support –no-single-branch
15 | command line parameter, then just remove it.*
16 |
--------------------------------------------------------------------------------
/docs/download/v4.3.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v4.3.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 4.3 (release series v4.3.x).
5 |
6 | ## Kamailio v4.3.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v4.3.x.
9 |
10 | git clone --depth --no-single-branch 1 git://git.sip-router.org/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 4.3 origin/4.3
13 |
14 | *Note: if your git client version does not support –no-single-branch
15 | command line parameter, then just remove it.*
16 |
--------------------------------------------------------------------------------
/docs/download/v4.4.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v4.4.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 4.4 (release series v4.4.x).
5 |
6 | ## Kamailio v4.4.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v4.4.x.
9 |
10 | git clone --depth --no-single-branch 1 https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 4.4 origin/4.4
13 |
14 | *Note: if your git client version does not support –no-single-branch
15 | command line parameter, then just remove it.*
16 |
--------------------------------------------------------------------------------
/docs/download/v5.0.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.0.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5,0 (release series v5.0.x).
5 |
6 | ## Kamailio v5.0.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.0.x.
9 |
10 | git clone --depth --no-single-branch 1 https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.0 origin/5.0
13 |
14 | *Note: if your git client version does not support –no-single-branch
15 | command line parameter, then just remove it.*
16 |
--------------------------------------------------------------------------------
/docs/download/v5.1.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.1.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.1 (release series v5.1.x).
5 |
6 | ## Kamailio v5.1.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.1.x.
9 |
10 | git clone --depth --no-single-branch 1 https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.1 origin/5.1
13 |
14 | *Note: if your git client version does not support –no-single-branch
15 | command line parameter, then just remove it.*
16 |
--------------------------------------------------------------------------------
/docs/download/v5.2.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.2.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.2 (release series v5.2.x).
5 |
6 | ## Kamailio v5.2.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.2.x.
9 |
10 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.2 origin/5.2
13 |
14 | *Note: if your git client version does not support **–no-single-branch**
15 | command line parameter, then just remove it.*
16 |
17 | *Note: if you want to have the full commit history, then remove
18 | **--depth 1** command line parameter.*
19 |
--------------------------------------------------------------------------------
/docs/download/v5.3.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.3.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.3 (release series v5.3.x).
5 |
6 | ## Kamailio v5.3.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.3.x.
9 |
10 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.3 origin/5.3
13 |
14 | *Note: if your git client version does not support **–no-single-branch**
15 | command line parameter, then just remove it.*
16 |
17 | *Note: if you want to have the full commit history, then remove
18 | **--depth 1** command line parameter.*
19 |
--------------------------------------------------------------------------------
/docs/download/v5.4.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.4.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.4 (release series v5.4.x).
5 |
6 | ## Kamailio v5.4.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.4.x.
9 |
10 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.4 origin/5.4
13 |
14 | *Note: if your git client version does not support **–no-single-branch**
15 | command line parameter, then just remove it.*
16 |
17 | *Note: if you want to have the full commit history, then remove
18 | **--depth 1** command line parameter.*
19 |
--------------------------------------------------------------------------------
/docs/download/v5.5.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.5.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.5 (release series v5.5.x).
5 |
6 | ## Kamailio v5.5.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.5.x.
9 |
10 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.5 origin/5.5
13 |
14 | *Note: if your git client version does not support **–no-single-branch**
15 | command line parameter, then just remove it.*
16 |
17 | *Note: if you want to have the full commit history, then remove
18 | **--depth 1** command line parameter.*
19 |
--------------------------------------------------------------------------------
/docs/download/v5.6.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.6.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.6 (release series v5.6.x).
5 |
6 | ## Kamailio v5.6.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.6.x.
9 |
10 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.6 origin/5.6
13 |
14 | *Note: if your git client version does not support **–no-single-branch**
15 | command line parameter, then just remove it.*
16 |
17 | *Note: if you want to have the full commit history, then remove
18 | **--depth 1** command line parameter.*
19 |
--------------------------------------------------------------------------------
/docs/download/v5.7.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.7.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.7 (release series v5.7.x).
5 |
6 | ## Kamailio v5.7.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.7.x.
9 |
10 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
11 | cd kamailio
12 | git checkout -b 5.7 origin/5.7
13 |
14 | *Note: if your git client version does not support **–no-single-branch**
15 | command line parameter, then just remove it.*
16 |
17 | *Note: if you want to have the full commit history, then remove
18 | **--depth 1** command line parameter.*
19 |
--------------------------------------------------------------------------------
/docs/download/v5.8.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v5.8.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 5.8 (release series v5.8.x).
5 |
6 | ## Kamailio v5.8.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v5.8.x.
9 |
10 | ```
11 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
12 | cd kamailio
13 | git checkout -b 5.8 origin/5.8
14 | ```
15 |
16 | *Note: if your git client version does not support **–no-single-branch**
17 | command line parameter, then just remove it.*
18 |
19 | Or, for newer git versions, with direct branch 5.8 checkout:
20 |
21 | ```
22 | git clone --depth 1 --branch 5.8 https://github.com/kamailio/kamailio kamailio
23 | cd kamailio
24 | ```
25 |
26 | *Note: if you want to have the full commit history, then remove
27 | **--depth 1** command line parameter.*
28 |
--------------------------------------------------------------------------------
/docs/download/v6.0.x-from-git.md:
--------------------------------------------------------------------------------
1 | # Download Sources of Kamailio v6.0.x from GIT Repository
2 |
3 | Instructions to download sources from GIT repository, specific for
4 | stable branch 6.0 (release series v6.0.x).
5 |
6 | ## Kamailio v6.0.x
7 |
8 | Direct download of sources from GIT for latest Kamailio v6.0.x.
9 |
10 | ```
11 | git clone --depth 1 --no-single-branch https://github.com/kamailio/kamailio kamailio
12 | cd kamailio
13 | git checkout -b 6.0 origin/6.0
14 | ```
15 |
16 | *Note: if your git client version does not support **–no-single-branch**
17 | command line parameter, then just remove it.*
18 |
19 | Or, for newer git versions, with direct branch 6.0 checkout:
20 |
21 | ```
22 | git clone --depth 1 --branch 6.0 https://github.com/kamailio/kamailio kamailio
23 | cd kamailio
24 | ```
25 |
26 | *Note: if you want to have the full commit history, then remove
27 | **--depth 1** command line parameter.*
28 |
--------------------------------------------------------------------------------
/docs/embeddedapi/3.2.x/perl.md:
--------------------------------------------------------------------------------
1 | # Perl API for Kamailio v3.2.x
2 |
3 | Module **perl** allows execution of Perl scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **perl** are available in the Perl
6 | script as package OpenSER.
7 |
8 | References:
9 |
10 | - **perl** module:
11 | [README](http://kamailio.org/docs/modules/3.2.x/modules_k/perl.html)
12 | - **Perl**:
13 |
14 | Perl API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/3.2.x/python.md:
--------------------------------------------------------------------------------
1 | # Python API for Kamailio v3.2.x
2 |
3 | Module **app_python** allows execution of Python scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **python** are available in the
6 | Python script as package SIPRouter.
7 |
8 | References:
9 |
10 | - **app_python** module:
11 | [README](http://kamailio.org/docs/modules/3.2.x/modules/app_python.html)
12 | - **Python**:
13 |
--------------------------------------------------------------------------------
/docs/embeddedapi/3.3.x/mono.md:
--------------------------------------------------------------------------------
1 | # Mono - C# API for Kamailio v3.3.x
2 |
3 | Kamailio can execute managed code assemblies via **app_mono** module:
4 |
5 | -
6 |
7 | The C# API exported by Kamailio to the embedded Mono interpreter is
8 | defined in **SR.cs** file located in source tree
9 | **modules/app_mono/lib/SR.cs**.
10 |
11 | To compile **SR.cs** to a library, use:
12 |
13 | ``` shell
14 | gmcs -t:library SR.cs
15 | ```
16 |
17 | This will generate the file **SR.dll**. To link your C# file to it, use:
18 |
19 | ``` shell
20 | gmcs -r:SR.dll MyFile.cs
21 | ```
22 |
23 | The API is stored in a **namespace**, named **SR**. The several classes
24 | offer access to internal Kamailio functionalities via public static
25 | functions.
26 |
27 | ## Class Core
28 |
29 | ### APIVersion
30 |
31 | ``` c
32 | public extern static string APIVersion();
33 | ```
34 |
35 | Return API version string.
36 |
37 | ### Log
38 |
39 | ``` c
40 | public extern static void Log(int level, string text);
41 | ```
42 |
43 | Write a message via Kamailio logging system to specified log level.
44 |
45 | ### Err
46 |
47 | ``` c
48 | public extern static void Err(string text);
49 | ```
50 |
51 | Write a message via Kamailio logging system to error log level.
52 |
53 | ### Dbg
54 |
55 | ``` c
56 | public extern static void Dbg(string text);
57 | ```
58 |
59 | Write a message via Kamailio logging system to debug log level.
60 |
61 | ### ModF
62 |
63 | ``` c
64 | public extern static int ModF(string text);
65 | ```
66 |
67 | Execute the function named by the value of parameter 'text' exported by
68 | a Kamailio module. It has to be a function with no parameters.
69 |
70 | ## Class PV
71 |
72 | ### GetS
73 |
74 | ``` c
75 | public extern static string GetS(string pvn);
76 | ```
77 |
78 | Get the string value of a pseudo-variable.
79 |
80 | ### GetI
81 |
82 | ``` c
83 | public extern static int GetI(string pvn);
84 | ```
85 |
86 | Get the integer value of a pseudo-variable.
87 |
88 | ### SetS
89 |
90 | ``` c
91 | public extern static int SetS(string pvn, string val);
92 | ```
93 |
94 | Set the pseudo-variable to a string value.
95 |
96 | ### SetI
97 |
98 | ``` c
99 | public extern static int SetI(string pvn, int val);
100 | ```
101 |
102 | Set the pseudo-variable to an integer value.
103 |
104 | ### Unset
105 |
106 | ``` c
107 | public extern static int Unset(string pvn);
108 | ```
109 |
110 | Unset the pseudo-variable (like assigning $null in kamailio.cfg).
111 |
112 | ### IsNull
113 |
114 | ``` c
115 | public extern static int IsNull(string pvn);
116 | ```
117 |
118 | Return true if the pseudo-variable is null.
119 |
120 | ## Class HDR
121 |
122 | ### Append
123 |
124 | ``` c
125 | public extern static int Append(string hv);
126 | ```
127 |
128 | Add a header to the end of the headers list. The parameter must be full
129 | header, including name, body header and ending '\\r\\n'.
130 |
131 | ### Remove
132 |
133 | ``` c
134 | public extern static int Remove(string name);
135 | ```
136 |
137 | Remove all headers matching the name.
138 |
139 | ### Insert
140 |
141 | ``` c
142 | public extern static int Insert(string hv);
143 | ```
144 |
145 | Add a header to the beginning of the headers list. The parameter must be
146 | full header, including name, body header and ending '\\r\\n'.
147 |
148 | ### AppendToReply
149 |
150 | ``` c
151 | public extern static int AppendToReply(string hv);
152 | ```
153 |
154 | Add a header to the headers list for local reply. The parameter must be
155 | full header, including name, body header and ending '\\r\\n'.
156 |
157 | ## Example
158 |
159 | A basic example of C# application using SR API:
160 |
161 | ``` c
162 | using SR;
163 |
164 | namespace MySRTest {
165 | class Test {
166 | static int Main(string[] args) {
167 | SR.Core.Log(1, "Kamailio API Version: " + SR.Core.APIVersion() + "\n");
168 | if (args.Length == 1) {
169 | SR.Core.Log(1, "Parameter from Kamailio config:"
170 | + args[0] + "\n");
171 | }
172 | SR.Core.Dbg("Request URI is: " + SR.PV.GetS("$ru") + "\n");
173 | SR.PV.SetS("$rU", "123");
174 | SR.HDR.AppendToReply("My-Mono-Hdr: ok\r\n");
175 | SR.Core.ModF("sl_reply_error");
176 | return 1;
177 | }
178 | }
179 | }
180 | ```
181 |
--------------------------------------------------------------------------------
/docs/embeddedapi/3.3.x/perl.md:
--------------------------------------------------------------------------------
1 | # Perl API for Kamailio v3.3.x
2 |
3 | Module **perl** allows execution of Perl scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **perl** are available in the Perl
6 | script as package OpenSER.
7 |
8 | References:
9 |
10 | - **perl** module:
11 | [README](http://kamailio.org/docs/modules/3.3.x/modules_k/perl.html)
12 | - **Perl**:
13 |
14 | Perl API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/3.3.x/python.md:
--------------------------------------------------------------------------------
1 | # Python API for Kamailio v3.3.x
2 |
3 | Module **app_python** allows execution of Python scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **python** are available in the
6 | Python script as package SIPRouter.
7 |
8 | References:
9 |
10 | - **app_python** module:
11 | [README](http://kamailio.org/docs/modules/3.3.x/modules/app_python.html)
12 | - **Python**:
13 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.0.x/mono.md:
--------------------------------------------------------------------------------
1 | # Mono - C# API for Kamailio v4.0.x
2 |
3 | Kamailio can execute managed code assemblies via **app_mono** module:
4 |
5 | -
6 |
7 | The C# API exported by Kamailio to the embedded Mono interpreter is
8 | defined in **SR.cs** file located in source tree
9 | **modules/app_mono/lib/SR.cs**.
10 |
11 | To compile **SR.cs** to a library, use:
12 |
13 | ``` shell
14 | gmcs -t:library SR.cs
15 | ```
16 |
17 | This will generate the file **SR.dll**. To link your C# file to it, use:
18 |
19 | ``` shell
20 | gmcs -r:SR.dll MyFile.cs
21 | ```
22 |
23 | The API is stored in a **namespace**, named **SR**. The several classes
24 | offer access to internal Kamailio functionalities via public static
25 | functions.
26 |
27 | ## Class Core
28 |
29 | ### APIVersion
30 |
31 | ``` c
32 | public extern static string APIVersion();
33 | ```
34 |
35 | Return API version string.
36 |
37 | ### Log
38 |
39 | ``` c
40 | public extern static void Log(int level, string text);
41 | ```
42 |
43 | Write a message via Kamailio logging system to specified log level.
44 |
45 | ### Err
46 |
47 | ``` c
48 | public extern static void Err(string text);
49 | ```
50 |
51 | Write a message via Kamailio logging system to error log level.
52 |
53 | ### Dbg
54 |
55 | ``` c
56 | public extern static void Dbg(string text);
57 | ```
58 |
59 | Write a message via Kamailio logging system to debug log level.
60 |
61 | ### ModF
62 |
63 | ``` c
64 | public extern static int ModF(string text);
65 | ```
66 |
67 | Execute the function named by the value of parameter 'text' exported by
68 | a Kamailio module. It has to be a function with no parameters.
69 |
70 | ## Class PV
71 |
72 | ### GetS
73 |
74 | ``` c
75 | public extern static string GetS(string pvn);
76 | ```
77 |
78 | Get the string value of a pseudo-variable.
79 |
80 | ### GetI
81 |
82 | ``` c
83 | public extern static int GetI(string pvn);
84 | ```
85 |
86 | Get the integer value of a pseudo-variable.
87 |
88 | ### SetS
89 |
90 | ``` c
91 | public extern static int SetS(string pvn, string val);
92 | ```
93 |
94 | Set the pseudo-variable to a string value.
95 |
96 | ### SetI
97 |
98 | ``` c
99 | public extern static int SetI(string pvn, int val);
100 | ```
101 |
102 | Set the pseudo-variable to an integer value.
103 |
104 | ### Unset
105 |
106 | ``` c
107 | public extern static int Unset(string pvn);
108 | ```
109 |
110 | Unset the pseudo-variable (like assigning $null in kamailio.cfg).
111 |
112 | ### IsNull
113 |
114 | ``` c
115 | public extern static int IsNull(string pvn);
116 | ```
117 |
118 | Return true if the pseudo-variable is null.
119 |
120 | ## Class HDR
121 |
122 | ### Append
123 |
124 | ``` c
125 | public extern static int Append(string hv);
126 | ```
127 |
128 | Add a header to the end of the headers list. The parameter must be full
129 | header, including name, body header and ending '\\r\\n'.
130 |
131 | ### Remove
132 |
133 | ``` c
134 | public extern static int Remove(string name);
135 | ```
136 |
137 | Remove all headers matching the name.
138 |
139 | ### Insert
140 |
141 | ``` c
142 | public extern static int Insert(string hv);
143 | ```
144 |
145 | Add a header to the beginning of the headers list. The parameter must be
146 | full header, including name, body header and ending '\\r\\n'.
147 |
148 | ### AppendToReply
149 |
150 | ``` c
151 | public extern static int AppendToReply(string hv);
152 | ```
153 |
154 | Add a header to the headers list for local reply. The parameter must be
155 | full header, including name, body header and ending '\\r\\n'.
156 |
157 | ## Example
158 |
159 | A basic example of C# application using SR API:
160 |
161 | ``` c
162 | using SR;
163 |
164 | namespace MySRTest {
165 | class Test {
166 | static int Main(string[] args) {
167 | SR.Core.Log(1, "Kamailio API Version: " + SR.Core.APIVersion() + "\n");
168 | if (args.Length == 1) {
169 | SR.Core.Log(1, "Parameter from Kamailio config:"
170 | + args[0] + "\n");
171 | }
172 | SR.Core.Dbg("Request URI is: " + SR.PV.GetS("$ru") + "\n");
173 | SR.PV.SetS("$rU", "123");
174 | SR.HDR.AppendToReply("My-Mono-Hdr: ok\r\n");
175 | SR.Core.ModF("sl_reply_error");
176 | return 1;
177 | }
178 | }
179 | }
180 | ```
181 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.0.x/perl.md:
--------------------------------------------------------------------------------
1 | # Perl API for Kamailio v4.0.x
2 |
3 | Module **app_perl** allows execution of Perl scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_perl** are available in the
6 | Perl script as package Kamailio.
7 |
8 | References:
9 |
10 | - **app_perl** module:
11 | [README](http://kamailio.org/docs/modules/4.0.x/modules/app_perl.html)
12 | - **Perl**:
13 |
14 | Perl API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.0.x/python.md:
--------------------------------------------------------------------------------
1 | # Python API for Kamailio v4.0.x
2 |
3 | Module **app_python** allows execution of Python scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **python** are available in the
6 | Python script as package SIPRouter.
7 |
8 | References:
9 |
10 | - **app_python** module:
11 | [README](http://kamailio.org/docs/modules/4.0.x/modules/app_python.html)
12 | - **Python**:
13 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.1.x/java.md:
--------------------------------------------------------------------------------
1 | # Java API for Kamailio v4.1.x
2 |
3 | Module **app\_** allows execution of Java code from Kamailio
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_java** can be available in the
6 | Java code as class Kamailio.
7 |
8 | References:
9 |
10 | - **app_java** module:
11 | [README](http://kamailio.org/docs/modules/4.1.x/modules/app_java.html)
12 | - **Java**:
13 |
14 | Java API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.1.x/mono.md:
--------------------------------------------------------------------------------
1 | # Mono - C# API for Kamailio v4.1.x
2 |
3 | Kamailio can execute managed code assemblies via **app_mono** module:
4 |
5 | -
6 |
7 | The C# API exported by Kamailio to the embedded Mono interpreter is
8 | defined in **SR.cs** file located in source tree
9 | **modules/app_mono/lib/SR.cs**.
10 |
11 | To compile **SR.cs** to a library, use:
12 |
13 | ``` shell
14 | gmcs -t:library SR.cs
15 | ```
16 |
17 | This will generate the file **SR.dll**. To link your C# file to it, use:
18 |
19 | ``` shell
20 | gmcs -r:SR.dll MyFile.cs
21 | ```
22 |
23 | The API is stored in a **namespace**, named **SR**. The several classes
24 | offer access to internal Kamailio functionalities via public static
25 | functions.
26 |
27 | ## Class Core
28 |
29 | ### APIVersion
30 |
31 | ``` c
32 | public extern static string APIVersion();
33 | ```
34 |
35 | Return API version string.
36 |
37 | ### Log
38 |
39 | ``` c
40 | public extern static void Log(int level, string text);
41 | ```
42 |
43 | Write a message via Kamailio logging system to specified log level.
44 |
45 | ### Err
46 |
47 | ``` c
48 | public extern static void Err(string text);
49 | ```
50 |
51 | Write a message via Kamailio logging system to error log level.
52 |
53 | ### Dbg
54 |
55 | ``` c
56 | public extern static void Dbg(string text);
57 | ```
58 |
59 | Write a message via Kamailio logging system to debug log level.
60 |
61 | ### ModF
62 |
63 | ``` c
64 | public extern static int ModF(string text);
65 | ```
66 |
67 | Execute the function named by the value of parameter 'text' exported by
68 | a Kamailio module. It has to be a function with no parameters.
69 |
70 | ## Class PV
71 |
72 | ### GetS
73 |
74 | ``` c
75 | public extern static string GetS(string pvn);
76 | ```
77 |
78 | Get the string value of a pseudo-variable.
79 |
80 | ### GetI
81 |
82 | ``` c
83 | public extern static int GetI(string pvn);
84 | ```
85 |
86 | Get the integer value of a pseudo-variable.
87 |
88 | ### SetS
89 |
90 | ``` c
91 | public extern static int SetS(string pvn, string val);
92 | ```
93 |
94 | Set the pseudo-variable to a string value.
95 |
96 | ### SetI
97 |
98 | ``` c
99 | public extern static int SetI(string pvn, int val);
100 | ```
101 |
102 | Set the pseudo-variable to an integer value.
103 |
104 | ### Unset
105 |
106 | ``` c
107 | public extern static int Unset(string pvn);
108 | ```
109 |
110 | Unset the pseudo-variable (like assigning $null in kamailio.cfg).
111 |
112 | ### IsNull
113 |
114 | ``` c
115 | public extern static int IsNull(string pvn);
116 | ```
117 |
118 | Return true if the pseudo-variable is null.
119 |
120 | ## Class HDR
121 |
122 | ### Append
123 |
124 | ``` c
125 | public extern static int Append(string hv);
126 | ```
127 |
128 | Add a header to the end of the headers list. The parameter must be full
129 | header, including name, body header and ending '\\r\\n'.
130 |
131 | ### Remove
132 |
133 | ``` c
134 | public extern static int Remove(string name);
135 | ```
136 |
137 | Remove all headers matching the name.
138 |
139 | ### Insert
140 |
141 | ``` c
142 | public extern static int Insert(string hv);
143 | ```
144 |
145 | Add a header to the beginning of the headers list. The parameter must be
146 | full header, including name, body header and ending '\\r\\n'.
147 |
148 | ### AppendToReply
149 |
150 | ``` c
151 | public extern static int AppendToReply(string hv);
152 | ```
153 |
154 | Add a header to the headers list for local reply. The parameter must be
155 | full header, including name, body header and ending '\\r\\n'.
156 |
157 | ## Example
158 |
159 | A basic example of C# application using SR API:
160 |
161 | ``` c
162 | using SR;
163 |
164 | namespace MySRTest {
165 | class Test {
166 | static int Main(string[] args) {
167 | SR.Core.Log(1, "Kamailio API Version: " + SR.Core.APIVersion() + "\n");
168 | if (args.Length == 1) {
169 | SR.Core.Log(1, "Parameter from Kamailio config:"
170 | + args[0] + "\n");
171 | }
172 | SR.Core.Dbg("Request URI is: " + SR.PV.GetS("$ru") + "\n");
173 | SR.PV.SetS("$rU", "123");
174 | SR.HDR.AppendToReply("My-Mono-Hdr: ok\r\n");
175 | SR.Core.ModF("sl_reply_error");
176 | return 1;
177 | }
178 | }
179 | }
180 | ```
181 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.1.x/perl.md:
--------------------------------------------------------------------------------
1 | # Perl API for Kamailio v4.1.x
2 |
3 | Module **app_perl** allows execution of Perl scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_perl** are available in the
6 | Perl script as package Kamailio.
7 |
8 | References:
9 |
10 | - **app_perl** module:
11 | [README](http://kamailio.org/docs/modules/4.1.x/modules/app_perl.html)
12 | - **Perl**:
13 |
14 | Perl API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.1.x/python.md:
--------------------------------------------------------------------------------
1 | # Python API for Kamailio v4.1.x
2 |
3 | Module **app_python** allows execution of Python scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **python** are available in the
6 | Python script as package SIPRouter.
7 |
8 | References:
9 |
10 | - **app_python** module:
11 | [README](http://kamailio.org/docs/modules/4.1.x/modules/app_python.html)
12 | - **Python**:
13 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.2.x/java.md:
--------------------------------------------------------------------------------
1 | # Java API for Kamailio 4.2.x Version
2 |
3 | Module **app\_** allows execution of Java code from Kamailio
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_java** can be available in the
6 | Java code as class Kamailio.
7 |
8 | References:
9 |
10 | - **app_java** module:
11 | [README](http://kamailio.org/docs/modules/4.2.x/modules/app_java.html)
12 | - **Java**:
13 |
14 | Java API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.2.x/mono.md:
--------------------------------------------------------------------------------
1 | # Mono - C# API for Kamailio 4.2.x Version
2 |
3 | Kamailio can execute managed code assemblies via **app_mono** module:
4 |
5 | -
6 |
7 | The C# API exported by Kamailio to the embedded Mono interpreter is
8 | defined in **SR.cs** file located in source tree
9 | **modules/app_mono/lib/SR.cs**.
10 |
11 | To compile **SR.cs** to a library, use:
12 |
13 | ``` shell
14 | gmcs -t:library SR.cs
15 | ```
16 |
17 | This will generate the file **SR.dll**. To link your C# file to it, use:
18 |
19 | ``` shell
20 | gmcs -r:SR.dll MyFile.cs
21 | ```
22 |
23 | The API is stored in a **namespace**, named **SR**. The several classes
24 | offer access to internal Kamailio functionalities via public static
25 | functions.
26 |
27 | ## Class Core
28 |
29 | ### APIVersion
30 |
31 | ``` c
32 | public extern static string APIVersion();
33 | ```
34 |
35 | Return API version string.
36 |
37 | ### Log
38 |
39 | ``` c
40 | public extern static void Log(int level, string text);
41 | ```
42 |
43 | Write a message via Kamailio logging system to specified log level.
44 |
45 | ### Err
46 |
47 | ``` c
48 | public extern static void Err(string text);
49 | ```
50 |
51 | Write a message via Kamailio logging system to error log level.
52 |
53 | ### Dbg
54 |
55 | ``` c
56 | public extern static void Dbg(string text);
57 | ```
58 |
59 | Write a message via Kamailio logging system to debug log level.
60 |
61 | ### ModF
62 |
63 | ``` c
64 | public extern static int ModF(string text);
65 | ```
66 |
67 | Execute the function named by the value of parameter 'text' exported by
68 | a Kamailio module. It has to be a function with no parameters.
69 |
70 | ## Class PV
71 |
72 | ### GetS
73 |
74 | ``` c
75 | public extern static string GetS(string pvn);
76 | ```
77 |
78 | Get the string value of a pseudo-variable.
79 |
80 | ### GetI
81 |
82 | ``` c
83 | public extern static int GetI(string pvn);
84 | ```
85 |
86 | Get the integer value of a pseudo-variable.
87 |
88 | ### SetS
89 |
90 | ``` c
91 | public extern static int SetS(string pvn, string val);
92 | ```
93 |
94 | Set the pseudo-variable to a string value.
95 |
96 | ### SetI
97 |
98 | ``` c
99 | public extern static int SetI(string pvn, int val);
100 | ```
101 |
102 | Set the pseudo-variable to an integer value.
103 |
104 | ### Unset
105 |
106 | ``` c
107 | public extern static int Unset(string pvn);
108 | ```
109 |
110 | Unset the pseudo-variable (like assigning $null in kamailio.cfg).
111 |
112 | ### IsNull
113 |
114 | ``` c
115 | public extern static int IsNull(string pvn);
116 | ```
117 |
118 | Return true if the pseudo-variable is null.
119 |
120 | ## Class HDR
121 |
122 | ### Append
123 |
124 | ``` c
125 | public extern static int Append(string hv);
126 | ```
127 |
128 | Add a header to the end of the headers list. The parameter must be full
129 | header, including name, body header and ending '\\r\\n'.
130 |
131 | ### Remove
132 |
133 | ``` c
134 | public extern static int Remove(string name);
135 | ```
136 |
137 | Remove all headers matching the name.
138 |
139 | ### Insert
140 |
141 | ``` c
142 | public extern static int Insert(string hv);
143 | ```
144 |
145 | Add a header to the beginning of the headers list. The parameter must be
146 | full header, including name, body header and ending '\\r\\n'.
147 |
148 | ### AppendToReply
149 |
150 | ``` c
151 | public extern static int AppendToReply(string hv);
152 | ```
153 |
154 | Add a header to the headers list for local reply. The parameter must be
155 | full header, including name, body header and ending '\\r\\n'.
156 |
157 | ## Example
158 |
159 | A basic example of C# application using SR API:
160 |
161 | ``` c
162 | using SR;
163 |
164 | namespace MySRTest {
165 | class Test {
166 | static int Main(string[] args) {
167 | SR.Core.Log(1, "Kamailio API Version: " + SR.Core.APIVersion() + "\n");
168 | if (args.Length == 1) {
169 | SR.Core.Log(1, "Parameter from Kamailio config:"
170 | + args[0] + "\n");
171 | }
172 | SR.Core.Dbg("Request URI is: " + SR.PV.GetS("$ru") + "\n");
173 | SR.PV.SetS("$rU", "123");
174 | SR.HDR.AppendToReply("My-Mono-Hdr: ok\r\n");
175 | SR.Core.ModF("sl_reply_error");
176 | return 1;
177 | }
178 | }
179 | }
180 | ```
181 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.2.x/perl.md:
--------------------------------------------------------------------------------
1 | # Perl API for Kamailio 4.2.x Version
2 |
3 | Module **app_perl** allows execution of Perl scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_perl** are available in the
6 | Perl script as package Kamailio.
7 |
8 | References:
9 |
10 | - **app_perl** module:
11 | [README](http://kamailio.org/docs/modules/4.2.x/modules/app_perl.html)
12 | - **Perl**:
13 |
14 | Perl API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.2.x/python.md:
--------------------------------------------------------------------------------
1 | # Python API for Kamailio 4.2.x Version
2 |
3 | Module **app_python** allows execution of Python scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **python** are available in the
6 | Python script as package SIPRouter.
7 |
8 | References:
9 |
10 | - **app_python** module:
11 | [README](http://kamailio.org/docs/modules/4.2.x/modules/app_python.html)
12 | - **Python**:
13 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.3.x/java.md:
--------------------------------------------------------------------------------
1 | # Java API for Kamailio 4.3.x Version
2 |
3 | Module **app\_** allows execution of Java code from Kamailio
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_java** can be available in the
6 | Java code as class Kamailio.
7 |
8 | References:
9 |
10 | - **app_java** module:
11 | [README](http://kamailio.org/docs/modules/4.3.x/modules/app_java.html)
12 | - **Java**:
13 |
14 | Java API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.3.x/mono.md:
--------------------------------------------------------------------------------
1 | # Mono - C# API for Kamailio 4.3.x Version
2 |
3 | Kamailio can execute managed code assemblies via **app_mono** module:
4 |
5 | -
6 |
7 | The C# API exported by Kamailio to the embedded Mono interpreter is
8 | defined in **SR.cs** file located in source tree
9 | **modules/app_mono/lib/SR.cs**.
10 |
11 | To compile **SR.cs** to a library, use:
12 |
13 | ``` shell
14 | gmcs -t:library SR.cs
15 | ```
16 |
17 | This will generate the file **SR.dll**. To link your C# file to it, use:
18 |
19 | ``` shell
20 | gmcs -r:SR.dll MyFile.cs
21 | ```
22 |
23 | The API is stored in a **namespace**, named **SR**. The several classes
24 | offer access to internal Kamailio functionalities via public static
25 | functions.
26 |
27 | ## Class Core
28 |
29 | ### APIVersion
30 |
31 | ``` c
32 | public extern static string APIVersion();
33 | ```
34 |
35 | Return API version string.
36 |
37 | ### Log
38 |
39 | ``` c
40 | public extern static void Log(int level, string text);
41 | ```
42 |
43 | Write a message via Kamailio logging system to specified log level.
44 |
45 | ### Err
46 |
47 | ``` c
48 | public extern static void Err(string text);
49 | ```
50 |
51 | Write a message via Kamailio logging system to error log level.
52 |
53 | ### Dbg
54 |
55 | ``` c
56 | public extern static void Dbg(string text);
57 | ```
58 |
59 | Write a message via Kamailio logging system to debug log level.
60 |
61 | ### ModF
62 |
63 | ``` c
64 | public extern static int ModF(string text);
65 | ```
66 |
67 | Execute the function named by the value of parameter 'text' exported by
68 | a Kamailio module. It has to be a function with no parameters.
69 |
70 | ## Class PV
71 |
72 | ### GetS
73 |
74 | ``` c
75 | public extern static string GetS(string pvn);
76 | ```
77 |
78 | Get the string value of a pseudo-variable.
79 |
80 | ### GetI
81 |
82 | ``` c
83 | public extern static int GetI(string pvn);
84 | ```
85 |
86 | Get the integer value of a pseudo-variable.
87 |
88 | ### SetS
89 |
90 | ``` c
91 | public extern static int SetS(string pvn, string val);
92 | ```
93 |
94 | Set the pseudo-variable to a string value.
95 |
96 | ### SetI
97 |
98 | ``` c
99 | public extern static int SetI(string pvn, int val);
100 | ```
101 |
102 | Set the pseudo-variable to an integer value.
103 |
104 | ### Unset
105 |
106 | ``` c
107 | public extern static int Unset(string pvn);
108 | ```
109 |
110 | Unset the pseudo-variable (like assigning $null in kamailio.cfg).
111 |
112 | ### IsNull
113 |
114 | ``` c
115 | public extern static int IsNull(string pvn);
116 | ```
117 |
118 | Return true if the pseudo-variable is null.
119 |
120 | ## Class HDR
121 |
122 | ### Append
123 |
124 | ``` c
125 | public extern static int Append(string hv);
126 | ```
127 |
128 | Add a header to the end of the headers list. The parameter must be full
129 | header, including name, body header and ending '\\r\\n'.
130 |
131 | ### Remove
132 |
133 | ``` c
134 | public extern static int Remove(string name);
135 | ```
136 |
137 | Remove all headers matching the name.
138 |
139 | ### Insert
140 |
141 | ``` c
142 | public extern static int Insert(string hv);
143 | ```
144 |
145 | Add a header to the beginning of the headers list. The parameter must be
146 | full header, including name, body header and ending '\\r\\n'.
147 |
148 | ### AppendToReply
149 |
150 | ``` c
151 | public extern static int AppendToReply(string hv);
152 | ```
153 |
154 | Add a header to the headers list for local reply. The parameter must be
155 | full header, including name, body header and ending '\\r\\n'.
156 |
157 | ## Example
158 |
159 | A basic example of C# application using SR API:
160 |
161 | ``` c
162 | using SR;
163 |
164 | namespace MySRTest {
165 | class Test {
166 | static int Main(string[] args) {
167 | SR.Core.Log(1, "Kamailio API Version: " + SR.Core.APIVersion() + "\n");
168 | if (args.Length == 1) {
169 | SR.Core.Log(1, "Parameter from Kamailio config:"
170 | + args[0] + "\n");
171 | }
172 | SR.Core.Dbg("Request URI is: " + SR.PV.GetS("$ru") + "\n");
173 | SR.PV.SetS("$rU", "123");
174 | SR.HDR.AppendToReply("My-Mono-Hdr: ok\r\n");
175 | SR.Core.ModF("sl_reply_error");
176 | return 1;
177 | }
178 | }
179 | }
180 | ```
181 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.3.x/perl.md:
--------------------------------------------------------------------------------
1 | # Perl API for Kamailio 4.3.x Version
2 |
3 | Module **app_perl** allows execution of Perl scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_perl** are available in the
6 | Perl script as package Kamailio.
7 |
8 | References:
9 |
10 | - **app_perl** module:
11 | [README](http://kamailio.org/docs/modules/4.3.x/modules/app_perl.html)
12 | - **Perl**:
13 |
14 | Perl API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/4.3.x/python.md:
--------------------------------------------------------------------------------
1 | # Python API for Kamailio 4.3.x Version
2 |
3 | Module **app_python** allows execution of Python scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **python** are available in the
6 | Python script as package SIPRouter.
7 |
8 | References:
9 |
10 | - **app_python** module:
11 | [README](http://kamailio.org/docs/modules/4.3.x/modules/app_python.html)
12 | - **Python**:
13 |
--------------------------------------------------------------------------------
/docs/embeddedapi/devel/java.md:
--------------------------------------------------------------------------------
1 | # Java API for Kamailio Devel Version
2 |
3 | Module **app\_** allows execution of Java code from Kamailio
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_java** can be available in the
6 | Java code as class Kamailio.
7 |
8 | References:
9 |
10 | - **app_java** module:
11 | [README](http://kamailio.org/docs/modules/devel/modules/app_java.html)
12 | - **Java**:
13 |
14 | Java API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/devel/mono.md:
--------------------------------------------------------------------------------
1 | # Mono - C# API for Kamailio Devel Version
2 |
3 | Kamailio can execute managed code assemblies via **app_mono** module:
4 |
5 | -
6 |
7 | The C# API exported by Kamailio to the embedded Mono interpreter is
8 | defined in **SR.cs** file located in source tree
9 | **modules/app_mono/lib/SR.cs**.
10 |
11 | To compile **SR.cs** to a library, use:
12 |
13 | ``` shell
14 | gmcs -t:library SR.cs
15 | ```
16 |
17 | This will generate the file **SR.dll**. To link your C# file to it, use:
18 |
19 | ``` shell
20 | gmcs -r:SR.dll MyFile.cs
21 | ```
22 |
23 | The API is stored in a **namespace**, named **SR**. The several classes
24 | offer access to internal Kamailio functionalities via public static
25 | functions.
26 |
27 | ## Class Core
28 |
29 | ### APIVersion
30 |
31 | ``` c
32 | public extern static string APIVersion();
33 | ```
34 |
35 | Return API version string.
36 |
37 | ### Log
38 |
39 | ``` c
40 | public extern static void Log(int level, string text);
41 | ```
42 |
43 | Write a message via Kamailio logging system to specified log level.
44 |
45 | ### Err
46 |
47 | ``` c
48 | public extern static void Err(string text);
49 | ```
50 |
51 | Write a message via Kamailio logging system to error log level.
52 |
53 | ### Dbg
54 |
55 | ``` c
56 | public extern static void Dbg(string text);
57 | ```
58 |
59 | Write a message via Kamailio logging system to debug log level.
60 |
61 | ### ModF
62 |
63 | ``` c
64 | public extern static int ModF(string text);
65 | ```
66 |
67 | Execute the function named by the value of parameter 'text' exported by
68 | a Kamailio module. It has to be a function with no parameters.
69 |
70 | ## Class PV
71 |
72 | ### GetS
73 |
74 | ``` c
75 | public extern static string GetS(string pvn);
76 | ```
77 |
78 | Get the string value of a pseudo-variable.
79 |
80 | ### GetI
81 |
82 | ``` c
83 | public extern static int GetI(string pvn);
84 | ```
85 |
86 | Get the integer value of a pseudo-variable.
87 |
88 | ### SetS
89 |
90 | ``` c
91 | public extern static int SetS(string pvn, string val);
92 | ```
93 |
94 | Set the pseudo-variable to a string value.
95 |
96 | ### SetI
97 |
98 | ``` c
99 | public extern static int SetI(string pvn, int val);
100 | ```
101 |
102 | Set the pseudo-variable to an integer value.
103 |
104 | ### Unset
105 |
106 | ``` c
107 | public extern static int Unset(string pvn);
108 | ```
109 |
110 | Unset the pseudo-variable (like assigning $null in kamailio.cfg).
111 |
112 | ### IsNull
113 |
114 | ``` c
115 | public extern static int IsNull(string pvn);
116 | ```
117 |
118 | Return true if the pseudo-variable is null.
119 |
120 | ## Class HDR
121 |
122 | ### Append
123 |
124 | ``` c
125 | public extern static int Append(string hv);
126 | ```
127 |
128 | Add a header to the end of the headers list. The parameter must be full
129 | header, including name, body header and ending '\\r\\n'.
130 |
131 | ### Remove
132 |
133 | ``` c
134 | public extern static int Remove(string name);
135 | ```
136 |
137 | Remove all headers matching the name.
138 |
139 | ### Insert
140 |
141 | ``` c
142 | public extern static int Insert(string hv);
143 | ```
144 |
145 | Add a header to the beginning of the headers list. The parameter must be
146 | full header, including name, body header and ending '\\r\\n'.
147 |
148 | ### AppendToReply
149 |
150 | ``` c
151 | public extern static int AppendToReply(string hv);
152 | ```
153 |
154 | Add a header to the headers list for local reply. The parameter must be
155 | full header, including name, body header and ending '\\r\\n'.
156 |
157 | ## Example
158 |
159 | A basic example of C# application using SR API:
160 |
161 | ``` c
162 | using SR;
163 |
164 | namespace MySRTest {
165 | class Test {
166 | static int Main(string[] args) {
167 | SR.Core.Log(1, "Kamailio API Version: " + SR.Core.APIVersion() + "\n");
168 | if (args.Length == 1) {
169 | SR.Core.Log(1, "Parameter from Kamailio config:"
170 | + args[0] + "\n");
171 | }
172 | SR.Core.Dbg("Request URI is: " + SR.PV.GetS("$ru") + "\n");
173 | SR.PV.SetS("$rU", "123");
174 | SR.HDR.AppendToReply("My-Mono-Hdr: ok\r\n");
175 | SR.Core.ModF("sl_reply_error");
176 | return 1;
177 | }
178 | }
179 | }
180 | ```
181 |
--------------------------------------------------------------------------------
/docs/embeddedapi/devel/perl.md:
--------------------------------------------------------------------------------
1 | # Perl API for Kamailio Devel Version
2 |
3 | Module **app_perl** allows execution of Perl scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **app_perl** are available in the
6 | Perl script as package Kamailio.
7 |
8 | References:
9 |
10 | - **app_perl** module:
11 | [README](http://kamailio.org/docs/modules/devel/modules/app_perl.html)
12 | - **Perl**:
13 |
14 | Perl API documentation is part of module README.
15 |
--------------------------------------------------------------------------------
/docs/embeddedapi/devel/python.md:
--------------------------------------------------------------------------------
1 | # Python API for Kamailio Devel Version
2 |
3 | Module **app_python** allows execution of Python scripts from SIP router
4 | configuration file, providing access to SIP message which is processed
5 | at that time. Exported functions by **python** are available in the
6 | Python script as package SIPRouter.
7 |
8 | References:
9 |
10 | - **app_python** module:
11 | [README](http://kamailio.org/docs/modules/devel/modules/app_python.html)
12 | - **Python**:
13 |
--------------------------------------------------------------------------------
/docs/features/new-in-devel.md:
--------------------------------------------------------------------------------
1 | # Kamailio SIP Server - New Features in Devel Version
2 |
3 | **Current devel version will be numbered 6.0.0 and it is planned to be
4 | released in late 2024 or early 2025**.
5 |
6 | **Previous devel, current stable, version was 5.8.x (released during the spring of 2024), see what was new in that release at:**
7 |
8 | -
9 |
10 | *This is a draft of new features added in devel version,
11 | manually updated, thus not always synchronized with what is new in
12 | source code repository.*
13 |
14 | ## New Modules
15 |
16 | ## New in existing Modules
17 |
18 | ### cfgutils
19 |
20 | - **lock** family functions got another optional key parameter to
21 | generate the hash id. See [#3808](https://github.com/kamailio/kamailio/pull/3808)
22 | or [cfgutils docs](https://www.kamailio.org/docs/modules/devel/modules/cfgutils.html)
23 | for details
24 |
25 | ### permissions
26 |
27 | - **allow_register_include_port()**, the permissions module got a new function, which extends
28 | a functionality for checking contacts (locations) allowed to be registered.
29 | With a newer function one has a possibility to include Contact URI port into this check.
30 | See [#3846](https://github.com/kamailio/kamailio/pull/3846)
31 | or [permissions docs](https://www.kamailio.org/docs/modules/devel/modules/permissions.html)
32 | for details.
33 |
34 | ### pua_dialoginfo
35 |
36 | - **use_uuid** optional parameter to generate pres_id using libuuid via uuid module
37 |
38 | ### rabbitmq
39 |
40 | - kamailio init will not fail if rabbitmq connection doesn't work. The module will try to reconnect
41 | when **rabbitmq_publish()** or **rabbitmq_publish_consume()** are called in the config.
42 |
43 | ### sca
44 |
45 | - **from_uri_avp** **to_uri_avp** module parameters adding the possibility of define what is the URI value
46 | for To and/or From instead of the values coming from the SIP message.
47 |
48 | ### siputils
49 |
50 | - **sip_p_charging_vector()** Once a new PCV has been generated by 'g' or 'f' the PCV cannot be changed
51 | again.
52 | The icid-generated-at parameter of a generated PCV will now be set to the sending interface IP address
53 | The function now returns a status value about what was done.
54 |
55 | - **$pcv(status)** New pseudo-variable parameter. Returns whether the PCV header was successfully parsed,
56 | deleted, newly generated or other.
57 | See [#3929](https://github.com/kamailio/kamailio/pull/3846)
58 | or [siputils](https://www.kamailio.org/docs/modules/devel/modules/siputils.html)
59 | for details.
60 |
61 | ## Archived Modules
62 |
63 | modules considered obsolete and not maintained have been moved to
64 |
65 |
66 | - auth_identity
67 | - app_lua_sr
68 | - app_sqlang
69 | - app_mono
70 |
71 | ## New in Core
72 |
73 | ### Command line arguments
74 |
75 | ### Interpreter
76 |
77 | ### Parameters
78 |
79 | ### Functions
80 |
81 | ### Memory Managers
82 |
83 | ### Architecture
84 |
85 | ### kamailio.cfg
86 |
87 | ## Tools
88 |
89 | ### kamcmd
90 |
91 | ### kamctl
92 |
93 | ### kamdbctl
94 |
95 | ### kamcli
96 |
--------------------------------------------------------------------------------
/docs/install/3.2.x/debian.md:
--------------------------------------------------------------------------------
1 | # Howto make Debian packages for Kamailio 3.2.x
2 |
3 | This Howto was tested with Kamailio 3.2.0. Nevertheless it should work
4 | also with older and newer versions.
5 |
6 | The build process for Debian packages generates all Kamailio packages
7 | (also mysql, postgres, radius ...). Thus, on the PC used for compiling
8 | the Debian packages, all required libraries must be installed, even if
9 | you do not install all packages afterwards.
10 |
11 | Thus, you need the client and development libraries for the database
12 | backends (mysql and postgres), openssl, xmpp and the radiusclient-ng
13 | libraries. These libraries are all included in Debian and can be easily
14 | installed using apt-get.
15 |
16 | Step 1-5 can be executed with normal user privileges, root privileges
17 | are only required for stop 6.
18 |
19 | ## 1. Get the Kamailio source code
20 |
21 | Either download a tar-ball or checkout the respective Kamilio branch
22 | from git.
23 |
24 | ## 2. Configure the build process
25 |
26 | Debian packages are built with the command "make deb". But this command
27 | is also used to build "ser" style Debian packages. Therefore, you have
28 | to advise the build process to build the "Kamailio" release when
29 | executing "make deb". This is done by setting the FLAVOR to "kamailio"
30 | when creating the build configuration.
31 |
32 | Execute (Note: Do not specify other build options here. You can specify
33 | them in the next step in the Debian rules file.):
34 |
35 | make FLAVOUR=kamailio cfg
36 |
37 | This instructs the build process to use pkg/kamailio/deb/debian/rules
38 | for creating the Debian packages.
39 |
40 | ## 3. Choose the Debian version
41 |
42 | Some new modules require libraries which are not in all Debian version.
43 | For example libjson0-dev is not available for Debian Lenny (5.0). In
44 | this case you either have to backport the required libraries to your
45 | Debian version or use the respective packaging files. In the second
46 | case, the respective modules will automatically disabled.
47 |
48 | For example if you want to build for Debian Squeeze and do not need the
49 | troublesome modules:
50 |
51 | cd pkg/kamailio/deb
52 | mv debian debian-orig
53 | ln -s squeeze debian
54 | cd ../../..
55 |
56 | ## 4. (optional) Add build options to the rules file
57 |
58 | If you want to activate certain build features, you can specify them in
59 | the Debian rules file.
60 |
61 | edit pkg/kamailio/deb/debian/rules:
62 |
63 | configure-stamp:
64 | dh_testdir
65 | # Add here commands to configure the package.
66 | $(MAKE) STUN=1 FLAVOUR=kamailio cfg prefix=/usr cfg_prefix=$(CURDIR)/debian/kamailio
67 |
68 | For example in above example the custom build parameter "STUN=1" was
69 | added.
70 |
71 | ## 5. Build the packages
72 |
73 | make deb
74 |
75 | If the build process fails due to missing dependencies install them via
76 | "apt-get install ....." and try "make deb" again.
77 |
78 | If the build succeeds, the packages are located in `../`
79 |
80 | ## 6. Install Kamailio
81 |
82 | Install Kamailio and the relevant Kamailio modules. For example to
83 | install Kamailio for MySQL and often needed modules:
84 |
85 | cd ..
86 | sudo dpkg -i kamailio_3.2.0_i386.deb kamailio-mysql-modules_3.2.0_i386.deb kamailio-tls-modules_3.2.0_i386.deb kamailio-utils-modules_3.2.0_i386.deb kamailio-xml-modules_3.2.0_i386.deb kamailio-xmlrpc-modules_3.2.0_i386.deb
87 |
--------------------------------------------------------------------------------
/docs/install/4.0.x/debian.md:
--------------------------------------------------------------------------------
1 | # Howto make Debian packages for Kamailio 4.0.x
2 |
3 | This Howto was tested with Kamailio 4.0.0. Nevertheless it should work
4 | also with newer versions.
5 |
6 | The build process for Debian packages generates all Kamailio packages
7 | (also mysql, postgres, radius ...). Thus, on the PC used for compiling
8 | the Debian packages, all required libraries must be installed, even if
9 | you do not install all packages afterwards.
10 |
11 | Thus, you need the client and development libraries for the database
12 | backends (mysql and postgres), openssl, xmpp and the radiusclient-ng
13 | libraries. These libraries are all included in Debian and can be easily
14 | installed using apt-get. (Try 'make deb' as described below, and if you
15 | get errors due to missing dependencies just install the respective
16 | packages.)
17 |
18 | Step 1-6 can be executed with normal user privileges, root privileges
19 | are only required for stop 7.
20 |
21 | ## 1. Get the Kamailio source code
22 |
23 | Either download a tar-ball or checkout the respective Kamilio branch
24 | from git.
25 |
26 | ## 2. Configure the build process
27 |
28 | Before building the Debian packages with the command "make deb", the
29 | build configuration has to be created. Since version 4.0, sip-router by
30 | default uses the "kamailio" flavor. Therefore, since 4.0 it is
31 | sufficient to generate the config without any special settings.
32 |
33 | Execute (Note: Do not specify other build options here. You can specify
34 | them in the next step in the Debian rules file.):
35 |
36 | make cfg
37 |
38 | This instructs the build process to use pkg/kamailio/deb/debian/rules
39 | for creating the Debian packages.
40 |
41 | ## 3. Choose the Debian version
42 |
43 | Some new modules require libraries which are not in all Debian version.
44 | For example libjson0-dev is not available for Debian Lenny (5.0). In
45 | this case you either have to backport the required libraries to your
46 | Debian version or use the respective packaging files. In the second
47 | case, the respective modules will automatically disabled.
48 |
49 | For example if you want to build for Debian Squeeze and do not need the
50 | troublesome modules:
51 |
52 | cd pkg/kamailio/deb
53 | mv debian debian-orig
54 | ln -s squeeze debian
55 | cd ../../..
56 |
57 | ## 4. (optional) Add build options to the rules file
58 |
59 | If you want to activate certain build features, you can specify them in
60 | the Debian rules file.
61 |
62 | edit pkg/kamailio/deb/debian/rules:
63 |
64 | configure-stamp:
65 | dh_testdir
66 | # Add here commands to configure the package.
67 | $(MAKE) STUN=1 FLAVOUR=kamailio cfg prefix=/usr cfg_prefix=$(CURDIR)/debian/kamailio
68 |
69 | For example in above example the custom build parameter "STUN=1" was
70 | added.
71 |
72 | ## 5. (optional) Tag your Debian package
73 |
74 | If you want to mark you self-built Debian package, add an entry on top
75 | of pkg/kamailio/deb/debian/changelog.
76 |
77 | ## 6. Build the packages
78 |
79 | make deb
80 |
81 | If the build process fails due to missing dependencies install them via
82 | "apt-get install ....." and try "make deb" again.
83 |
84 | If the build succeeds, the packages are located in `../`
85 |
86 | ## 7. Install Kamailio
87 |
88 | Install Kamailio and the relevant Kamailio modules. For example to
89 | install Kamailio for MySQL and often needed modules:
90 |
91 | cd ..
92 | sudo dpkg -i kamailio_4.0.0_i386.deb kamailio-mysql-modules_4.0.0_i386.deb kamailio-tls-modules_4.0.0_i386.deb kamailio-utils-modules_4.0.0_i386.deb kamailio-xml-modules_4.0.0_i386.deb kamailio-xmlrpc-modules_4.0.0_i386.deb
93 |
--------------------------------------------------------------------------------
/docs/install/container/docker.md:
--------------------------------------------------------------------------------
1 | # Install Kamailio On Docker
2 |
3 | Due to [Docker Hub restrictions](https://www.docker.com/blog/scaling-dockers-business-to-serve-millions-more-developers-storage/) we migrated
4 | to Github Packages Registry.
5 |
6 | The **ghcr.io/kamailio/kamailio** docker image is using Debian. If you are
7 | familiar with Debian, then this image may be a choice to start with and
8 | extend.
9 |
10 | The **ghcr.io/kamailio/kamailio-ci** docker image is using Alpine. Alpine allows
11 | to create smaller and secure docker images.
12 |
13 | Kamailio images can be seen at:
14 |
15 | -
16 | -
17 |
--------------------------------------------------------------------------------
/docs/install/stable/debian.md:
--------------------------------------------------------------------------------
1 | # Install Kamailio On Debian
2 |
3 | Kamailio packages are included in the official Debian Stable repository.
4 | At the time of writing the initial version of this tutorial, Debian
5 | Stable codename is Jessie, version 8.x.
6 |
7 | The focus of this tutorial is to install Kamailio with MySQL backend.
8 |
9 | ## APT Install Commands
10 |
11 | ``` bash
12 | apt-get update
13 | apt-get install mysql-server
14 | apt-get install kamailio kamailio-mysql-modules
15 | ```
16 |
17 | ## Config Files
18 |
19 | Configuration files are located in **/etc/kamailio/** folder.
20 |
21 | ### Kamctlrc
22 |
23 | The **/etc/kamailio/kamctlrc** is the configuration file for **kamctl**
24 | and **kamdbctl**. You need to edit it and set the **SIP_DOMAIN** to your
25 | SIP service domain (or IP address if you don't have a DNS hostname
26 | associated with your SIP service).
27 |
28 | Set also the **DBENGINE** to be MYSQL and adjust other setting as you
29 | want.
30 |
31 | ### Kamailio.cfg
32 |
33 | The **/etc/kamailio/kamailio.cfg** is the configuration file for
34 | **kamailio**. Edit it to enable some of the features shipped with it.
35 |
36 | To enable use of MySQL backed, user authentication and persistent user
37 | location, add after the first line:
38 |
39 | ``` c
40 | #!define WITH_MYSQL
41 | #!define WITH_AUTH
42 | #!define WITH_USRLOCDB
43 | ```
44 |
45 | ## Create Database
46 |
47 | To create the database structure needed by Kamailio, run:
48 |
49 | ``` bash
50 | kamdbctl create
51 | ```
52 |
53 | ## Startup Scripts
54 |
55 | ### Init.d Scripts
56 |
57 | Depending on startup system, you may have an **/etc/init.d/kamailio**
58 | script that you can use to start/stop kamailio.
59 |
60 | First you should edit **/etc/default/kamailio** and adjust the setting
61 | for kamailio startup script, in particular the one that enables kamailio
62 | to start.
63 |
64 | ``` bash
65 | /etc/init.d/kamailio start
66 | /etc/init.d/kamailio stop
67 | ```
68 |
69 | ### Systemd Scripts
70 |
71 | If the default startup system is systemd, then kamailio can be managed
72 | via systemctl:
73 |
74 | ``` bash
75 | systemctl start kamailio
76 | systemctl stop kamailio
77 | ```
78 |
79 | First you may also need to edit **/etc/default/kamailio** and adjust the
80 | setting for kamailio startup script, in particular the one that enables
81 | kamailio to start.
82 |
83 | If you edit the systemd unit file in order to add your own functions,
84 | you need to make sure that you make a copy of the unit file in
85 | **/etc/systemd/system** in order to avoid any updates in packages to
86 | overwrite your modified file with the standard one.
87 |
88 | ## Adding Subscribers
89 |
90 | To add subscribers (users), you can use the **kamctl** command:
91 |
92 | ``` bash
93 | kamctl add userid password
94 | ```
95 |
96 | Like:
97 |
98 | ``` bash
99 | kamctl add alice secret
100 | ```
101 |
102 | ## Alternative APT Repositories
103 |
104 | You can check the list of APT repositories offered by Kamailio project
105 | for various Debian or Ubuntu versions:
106 |
107 | - [DEBS: Debian - Ubuntu](../../packages/debs.md)
108 |
--------------------------------------------------------------------------------
/docs/install/upgrade/3.3.x-to-devel.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v3.3.x to devel
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of devel compared with what existed in
5 | v3.3.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v3.3.x to run with Kamailio
7 | devel.
8 |
9 | ## Modules
10 |
11 | These sections presents notes, listed by modules, about changes that
12 | need to be made to Kamailio configuration file when upgrading from
13 | Kamailio v3.3.x to devel.
14 |
15 | ### modules/tm
16 |
17 | - Changed value of module parameter contacts_avp from AVP definition
18 | to XAVP name (string).
19 | - Added new module parameter contact_flows_avp that needs to be
20 | defined if contacts_avp parameter has been defined.
21 |
--------------------------------------------------------------------------------
/docs/install/upgrade/4.1.x-to-4.2.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v4.1.x to v4.2.0
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v4.2.0 compared with what existed
5 | in v4.1.x.
6 |
7 | It does not include the brand new modules, focusing on how to upgrade
8 | database and configuration file from v4.1.x to run with Kamailio 4.2.x.
9 |
10 | The draft with what is new in release 4.2.x is available at:
11 |
12 | - [New Features in Release 4.2.x](../../features/new-in-4.2.x.md)
13 |
14 | ## Previous Stable Release
15 |
16 | If you look for the guidelines to upgrade to previous stable release,
17 | see:
18 |
19 | - [Upgrade Kamailio v4.0.x to v4.1.0](4.0.x-to-4.1.0.md)
20 |
21 | ## Remarks
22 |
23 | Following tokens are used to mark the changes:
24 |
25 | - INF - the change doesn't really have any direct impact to config
26 | content - no action required in old config
27 | - CPM - the change was used with the new value via explicit parameter
28 | in default config file from old releases
29 | - RCM - the change is recommended to be done if you had an explicit
30 | different or lower value for this parameter in old config
31 |
32 | ## Modules
33 |
34 | ### usrloc
35 |
36 | - default value for hash_size is 10 (1024 slots) (INF)
37 | - parameter db_ops_ruid is set to 1 (RCM)
38 |
39 | ### tm
40 |
41 | - parameter failure_reply_mode is set to 3 (CPM)
42 |
43 | ### auth_db
44 |
45 | - load_credentials default value is now "" instead of "rpid". (CPM)
46 |
47 | ## Core
48 |
49 | ### Parameters
50 |
51 | Changes to default values:
52 |
53 | - pkg (private) memory size: 8MB (INF)
54 | - shm (shared) memory size: 64MB (INF)
55 | - tcp read buffer size: 16kB (RCM)
56 | - pv print buffer size: 8kB (RCM)
57 |
58 | ## Database
59 |
60 | There are quite minimal changes to the database structure, in short:
61 |
62 | - acc table has the size of column sip_reason increased to 128
63 | - dialplan table has the size of column repl_exp increased to 64
64 | - dialplan table has the size of column repl_attrs increased to 64
65 | - missed_calls table has the size of column sip_reason increased to
66 | 128
67 |
68 | ### Upgrade Old MySQL Database Structure
69 |
70 | Run following SQL statements in MySQL client to upgrade database
71 | structure from v4.1 to v4.2:
72 |
73 | ``` sql
74 | -- table: acc
75 | ALTER TABLE acc CHANGE COLUMN sip_reason sip_reason varchar(128) DEFAULT '' NOT NULL;
76 | DELETE FROM version WHERE table_name='acc';
77 | INSERT INTO version (`table_name`, `table_version`) values ('acc','5');
78 |
79 | -- table: dialplan
80 | ALTER TABLE dialplan CHANGE COLUMN repl_exp repl_exp varchar(64) NOT NULL;
81 | ALTER TABLE dialplan CHANGE COLUMN attrs attrs varchar(64) NOT NULL;
82 | DELETE FROM version WHERE table_name='dialplan';
83 | INSERT INTO version (`table_name`, `table_version`) values ('dialplan','2');
84 |
85 | -- table: missed_calls
86 | ALTER TABLE missed_calls CHANGE COLUMN sip_reason sip_reason varchar(128) DEFAULT '' NOT NULL;
87 | DELETE FROM version WHERE table_name='missed_calls';
88 | INSERT INTO version (`table_name`, `table_version`) values ('missed_calls','4');
89 |
90 | ```
91 |
92 | ### Upgrade Old Postgresql Database Structure
93 |
94 | Run following SQL statements in psql client to upgrade database
95 | structure from v4.1 to v4.2:
96 |
97 | ``` sql
98 | -- table: acc
99 | ALTER TABLE acc ALTER COLUMN sip_reason TYPE VARCHAR(128);
100 | DELETE FROM version WHERE TABLE_NAME='acc';
101 | INSERT INTO version (`table_name`, `table_version`) VALUES ('acc','5');
102 |
103 | -- table: dialplan
104 | ALTER TABLE dialplan ALTER COLUMN repl_exp TYPE VARCHAR(64);
105 | ALTER TABLE dialplan ALTER COLUMN attrs TYPE VARCHAR(64);
106 | DELETE FROM version WHERE TABLE_NAME='dialplan';
107 | INSERT INTO version (table_name, table_version) VALUES ('dialplan','2');
108 |
109 | -- table: missed_calls
110 | ALTER TABLE missed_calls ALTER COLUMN sip_reason TYPE VARCHAR(128);
111 | DELETE FROM version WHERE TABLE_NAME='missed_calls';
112 | INSERT INTO version (table_name, table_version) VALUES ('missed_calls','4');
113 | ```
114 |
--------------------------------------------------------------------------------
/docs/install/upgrade/4.3.x-to-4.4.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v4.3.x to v4.4.0
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v4.4.0 compared with what existed
5 | in v4.3.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v4.3.x to run with Kamailio
7 | devel.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v4.2.x to v4.3.0](../upgrade/4.2.x-to-4.3.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 |
27 | ## Modules
28 |
29 | ### ims_dialog
30 |
31 | The **dialog-ng** module was renamed to **ims_dialog**.
32 |
33 | The modparams statements in your configuration file must be updated to
34 | reflect the new name of the module.
35 |
36 | ``` c
37 | # old version
38 | modparam("dialog-ng", ...)
39 |
40 | # new version
41 | modparam("ims_dialog", ...)
42 | ```
43 |
44 | The functions for routing blocks are the same, no changes are required
45 | there.
46 |
47 | ## Core
48 |
49 | ### Parameters
50 |
51 | #### fork
52 |
53 | (INF) This is just heads up notification that the **fork** parameter is
54 | planned to be refactored in the next version, because **fork=no**
55 | disables many features without explicit visibility (e.g., no tcp/tls,
56 | only listening on first network interface). The value **fork=yes** will
57 | preserve existing behaviour.
58 |
59 | ## Database
60 |
61 | There are quite minimal changes to the database structure, in short:
62 |
63 | - presence active_watchers table has new columns
64 | - permissions trusted table has new columns
65 | - uac uacreg table has new columns
66 |
67 | ### MySQL Database Structure
68 |
69 | Run following SQL statements in MySQL client to upgrade database
70 | structure from v4.3 to v4.4:
71 |
72 | ``` sql
73 | -- table: active_watchers
74 | ALTER TABLE active_watchers
75 | ADD COLUMN flags int(11) NOT NULL DEFAULT '0',
76 | ADD COLUMN user_agent varchar(255) DEFAULT '' NOT NULL;
77 | DELETE FROM version WHERE TABLE_NAME='active_watchers';
78 | INSERT INTO version (`table_name`, `table_version`) VALUES ('active_watchers','12');
79 |
80 | -- table: trusted
81 | ALTER TABLE `trusted`
82 | ADD COLUMN priority int(11) NOT NULL DEFAULT '0',
83 | ADD COLUMN ruri_pattern varchar(64) NULL,
84 | CHANGE COLUMN tag tag varchar(64) NULL;
85 | DELETE FROM version WHERE TABLE_NAME='trusted';
86 | INSERT INTO version (`table_name`, `table_version`) VALUES ('trusted','6');
87 |
88 | -- table: uacreg
89 | ALTER TABLE uacreg
90 | ADD COLUMN reg_delay int(11) NOT NULL DEFAULT '0',
91 | ADD COLUMN flags int(11) NOT NULL DEFAULT '0';
92 | DELETE FROM version WHERE TABLE_NAME='uacreg';
93 | INSERT INTO version (`table_name`, `table_version`) VALUES ('uacreg','2');
94 |
95 |
96 | ```
97 |
98 | ### Postgres Database Structure
99 |
100 | Run following SQL statements in psql client to upgrade database
101 | structure from v4.3 to v4.4:
102 |
103 | ``` sql
104 | -- table: active_watchers
105 | ALTER TABLE active_watchers ADD COLUMN flags INTEGER DEFAULT 0 NOT NULL;
106 | ALTER TABLE active_watchers ADD COLUMN user_agent VARCHAR(255) DEFAULT '' NOT NULL;
107 | DELETE FROM version WHERE TABLE_NAME='active_watchers';
108 | INSERT INTO version (TABLE_NAME, table_version) VALUES ('active_watchers','12');
109 |
110 | -- table: trusted
111 | ALTER TABLE trusted ADD COLUMN priority INTEGER DEFAULT 0 NOT NULL;
112 | ALTER TABLE trusted ADD COLUMN ruri_pattern VARCHAR(64) NULL;
113 | ALTER TABLE trusted ALTER COLUMN tag TYPE VARCHAR(64);
114 | DELETE FROM version WHERE TABLE_NAME='trusted';
115 | INSERT INTO version (TABLE_NAME, table_version) VALUES ('trusted','6');
116 |
117 | -- table: uacreg
118 | ALTER TABLE uacreg ADD COLUMN reg_delay INTEGER DEFAULT 0 NOT NULL;
119 | ALTER TABLE uacreg ADD COLUMN flags INTEGER DEFAULT 0 NOT NULL;
120 | DELETE FROM version WHERE TABLE_NAME='uacreg';
121 | INSERT INTO version (TABLE_NAME, table_version) VALUES ('uacreg','2');
122 |
123 | ```
124 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.0.x-to-5.1.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.0.x to v5.1.0 (stable)
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v5.1.0 compared with what existed
5 | in v5.0.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v5.0.x to run with Kamailio
7 | v5.1.0.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v4.4.x to v5.0.0](4.4.x-to-5.0.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 |
27 | ## Modules
28 |
29 | ### Removed Modules
30 |
31 | - none
32 |
33 | ### Renamed Modules
34 |
35 | - **acc_diameter** has been split for **acc** module
36 |
37 | ## Internal Libraries
38 |
39 | - no major change that impacts the configuration file
40 |
41 | ## Core
42 |
43 | ### Parameters
44 |
45 | - no major change that impacts the configuration file
46 |
47 | ## Database
48 |
49 | - increased size of dialplan table repl_exp field to 256 chars
50 |
51 | ### MySQL Database Structure
52 |
53 | Run following SQL statements in MySQL client to upgrade database
54 | structure from v5.0 to v5.1:
55 |
56 | ``` sql
57 | ALTER TABLE lcr_rule ADD COLUMN mt_tvalue VARCHAR(128) DEFAULT NULL AFTER request_uri;
58 | UPDATE version SET table_version=3 WHERE table_name='lcr_rule';
59 | ```
60 |
61 | ``` sql
62 | ALTER TABLE location MODIFY contact VARCHAR(512) NOT NULL DEFAULT '';
63 | UPDATE version SET table_version=9 WHERE table_name='location';
64 | ```
65 |
66 | ``` sql
67 | ALTER TABLE active_watchers CHANGE COLUMN reason reason varchar(64) DEFAULT NULL; -- # was varchar(64) NOT NULL
68 | ALTER TABLE domain_attrs DROP INDEX domain_attrs_idx; -- # was UNIQUE (did,name,value)
69 | ALTER TABLE domain_attrs ADD INDEX domain_attrs_idx (did,name);
70 | -- ALTER TABLE lcr_rule ADD COLUMN mt_tvalue varchar(128) DEFAULT NULL;
71 | -- ALTER TABLE location CHANGE COLUMN contact contact varchar(512) NOT NULL DEFAULT ''; # was varchar(255) NOT NULL DEFAULT ''
72 | ALTER TABLE topos_d ADD INDEX a_uuid_idx (a_uuid);
73 | ALTER TABLE topos_d ADD INDEX b_uuid_idx (b_uuid);
74 | ALTER TABLE topos_t ADD INDEX x_vbranch_idx (x_vbranch);
75 | ALTER TABLE topos_t ADD INDEX a_uuid_idx (a_uuid);
76 | ```
77 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.1.x-to-5.2.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.1.x to v5.2.0
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v5.2.0 compared with what existed
5 | in v5.1.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v5.1.x to run with Kamailio
7 | devel.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.0.x to v5.1.0](5.0.x-to-5.1.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - UPG - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | #### dispatcher
34 |
35 | UPG: Several parameters that were used to specify AVP names were
36 | removed, you have to remove the appropriate config modparams:
37 |
38 | ``` c
39 | modparam("dispatcher", "dst_avp", "$avp(AVP_DST)")
40 | modparam("dispatcher", "grp_avp", "$avp(AVP_GRP)")
41 | modparam("dispatcher", "cnt_avp", "$avp(AVP_CNT)")
42 | modparam("dispatcher", "sock_avp", "$avp(AVP_SOCK)")
43 | modparam("dispatcher", "attrs_avp", "$avp(AVP_ATTRS)")
44 | ```
45 |
46 | Starting with v5.2.0, the module is using XAVPs instead of those AVPs,
47 | the related parameters are:
48 |
49 | - xavp_dst
50 | - xavp_dst_mode
51 | - xavp_ctx
52 | - xavp_ctx_mode
53 |
54 | See:
55 |
56 |
57 | #### presence
58 |
59 | A new column 'ruid' has been added to the **presentity** table (used for
60 | distributing presence documents via dmq). This table holds the records
61 | corresponding to the PUBLISH requests sent by UAs.
62 |
63 | The cleanest way to upgrade is:
64 |
65 | - stop kamailio 5.1
66 | - delete records from presentity table
67 | - update the structure of presentity table
68 | - start kamailio 5.2
69 |
70 | The UAs will send new PUBLISH periodically, so the table will get
71 | populated again. If you want to shorten the interval for PUBLISH
72 | requests, set max_expire parameter for presence module, then restart and
73 | wait some time until all UAs send another PUBLISH. Do the upgrade as
74 | described above, and then set back the max_expire to the older value.
75 |
76 | ### Removed Modules
77 |
78 | - none
79 |
80 | ### Renamed Modules
81 |
82 | - none
83 |
84 | ## Internal Libraries
85 |
86 | ## Core
87 |
88 | ### Parameters
89 |
90 | ### Misc
91 |
92 | #### Log Messages
93 |
94 | The order of the attributes printed in the log messages was changed to
95 | have the log level first -- it was:
96 |
97 | $log-prefix $log-level $log-message
98 |
99 | Now it is:
100 |
101 | $log-level $log-prefix $log-message
102 |
103 | ## Database
104 |
105 | ### MySQL Database Structure
106 |
107 | Run following SQL statements in MySQL client to upgrade database
108 | structure from v5.1 to v5.2:
109 |
110 | ``` sql
111 | -- location table - optional update
112 | ALTER TABLE location_attrs CHANGE COLUMN avalue avalue varchar(512) NOT NULL DEFAULT '';
113 |
114 | -- presentity table
115 | ALTER TABLE presentity CHANGE COLUMN etag etag varchar(128) NOT NULL;
116 | ALTER TABLE presentity ADD COLUMN ruid VARCHAR(64);
117 | CREATE UNIQUE INDEX ruid_idx ON presentity (ruid);
118 | UPDATE version SET table_version=5 WHERE table_name='presentity';
119 |
120 | -- pua table - optional update
121 | ALTER TABLE pua CHANGE COLUMN etag etag varchar(128) NOT NULL;
122 |
123 | -- subscriber table - optional update
124 | ALTER TABLE subscriber DROP COLUMN rpid;
125 | ALTER TABLE subscriber DROP COLUMN email_address;
126 |
127 | -- xcap table - optional update
128 | ALTER TABLE xcap CHANGE COLUMN etag etag varchar(128) NOT NULL;
129 | ```
130 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.3.x-to-5.4.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.3.x to v5.4.0
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v5.4.0 compared with what existed
5 | in v5.3.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v5.3.x to run with Kamailio
7 | devel.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.2.x to v5.3.0](5.2.x-to-5.3.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - UPG - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | #### corex
34 |
35 | - non-sip network message processing parameters renamed:
36 | - network_io_intercept => nio_intercept
37 | - min_msg_len => nio_min_msg_len
38 | - msg_avp => nio_msg_avp
39 |
40 | #### sipcapture
41 |
42 | * promiscious_on parameter was replaced by promiscuous_on (UPG)
43 |
44 | ### Removed Modules
45 |
46 | - none
47 |
48 | ### Renamed Modules
49 |
50 | - none
51 |
52 | ## Internal Libraries
53 |
54 | ## Core
55 |
56 | ### Parameters
57 |
58 | ### Misc
59 |
60 | ## Database
61 |
62 | ### MySQL Database Structure
63 |
64 | Run following SQL statements in MySQL client to upgrade database
65 | structure from v5.3 to v5.4:
66 |
67 | ``` sql
68 | -- version table - added id column to facilitate records management with external tools
69 | -- * the column is not used by Kamailio, thus is optional to be create
70 |
71 | ALTER TABLE `version` ADD COLUMN `id` INT(10) UNSIGNED NOT NULL AUTO_INCREMENT, ADD PRIMARY KEY (`id`);
72 |
73 | ```
74 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.4.x-to-5.5.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.4.x to v5.5.0 (devel)
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v5.5.0 compared with what existed
5 | in v5.4.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v5.4.x to run with Kamailio
7 | 5.5.0.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.3.x to v5.4.0](5.3.x-to-5.4.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - UPG - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | - none
34 |
35 | ### Removed Modules
36 |
37 | - none
38 |
39 | ### Renamed Modules
40 |
41 | #### userblacklist to userblocklist
42 |
43 | -
44 |
45 | Impacted resources:
46 |
47 | - version table, userblacklist and globalblacklist entries renamed to
48 | userblocklist and globalblocklist
49 | - database table **globalblacklist** renamed to **globalblocklist** -
50 | its definition is now:
51 |
52 |
53 |
54 | CREATE TABLE globalblocklist (
55 | id int(10) unsigned NOT NULL AUTO_INCREMENT,
56 | prefix varchar(64) NOT NULL DEFAULT '',
57 | allowlist tinyint(1) NOT NULL DEFAULT 0,
58 | description varchar(255) DEFAULT NULL,
59 | PRIMARY KEY (id),
60 | KEY globalblocklist_idx (prefix)
61 | );
62 |
63 | Note also the changes in the column names and indexes.
64 |
65 | - database table **userblacklist** renamed to **userblocklist** - its
66 | definition is now:
67 |
68 |
69 |
70 | CREATE TABLE userblocklist (
71 | id int(10) unsigned NOT NULL AUTO_INCREMENT,
72 | username varchar(64) NOT NULL DEFAULT '',
73 | domain varchar(64) NOT NULL DEFAULT '',
74 | prefix varchar(64) NOT NULL DEFAULT '',
75 | allowlist tinyint(1) NOT NULL DEFAULT 0,
76 | PRIMARY KEY (id),
77 | KEY userblocklist_idx (username,domain,prefix)
78 | );
79 |
80 | Note also the changes in the column names and indexes.
81 |
82 | ## Internal Libraries
83 |
84 | ## Core
85 |
86 | ### Parameters
87 |
88 | #### Dst Blocklist Parameters
89 |
90 | All global parameters related to dst blocking are now using blocklist
91 | instead of blacklist in the name, see:
92 |
93 | -
94 |
95 | For example, **use_dst_blacklist** used in older versions has to be
96 | replaced by **use_dst_blocklist**.
97 |
98 | ### Misc
99 |
100 | - **#!substdef "/match/replacement/flags"** evaluates the
101 | **replacement** for variables to be coherent with **#!subst**, if
102 | there are variables that should not be evaluated during
103 | pre-processing phase, use **$$** at the beginning of variable (e.g.,
104 | **$$var(x)**\*
105 |
106 | ## Database
107 |
108 | ### MySQL Database Structure
109 |
110 | Run following SQL statements in MySQL client to upgrade database
111 | structure from v5.4 to v5.5:
112 |
113 | ``` sql
114 | -- topos_d table
115 | ALTER TABLE topos_d ADD COLUMN x_context varchar(64) NOT NULL DEFAULT '';
116 | UPDATE version SET table_version=2 WHERE TABLE_NAME='topos_d';
117 |
118 | -- topos_t table
119 | ALTER TABLE topos_t ADD COLUMN x_context varchar(64) NOT NULL DEFAULT '';
120 | UPDATE version SET table_version=2 WHERE TABLE_NAME='topos_t';
121 |
122 | -- uacreg table
123 | ALTER TABLE uacreg ADD COLUMN contact_addr varchar(255) NOT NULL DEFAULT '';
124 | UPDATE version SET table_version=5 WHERE TABLE_NAME='uacreg';
125 |
126 | -- IMPORTANT: see also the notes about the userblocklist module
127 | ```
128 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.5.x-to-5.6.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.5.x to v5.6.0 (pre)
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of `v5.6.0` compared with what existed
5 | in `v5.5.x`. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from `v5.5.x` to run with Kamailio
7 | `5.6.0`.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.4.x to v5.5.0](5.4.x-to-5.5.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - `INF` - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - `CPM` - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - `RCM` - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - `UPG` - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | #### dispatcher
34 |
35 | - rpc command to add a record updated to set priority
36 |
37 | #### presence
38 |
39 | - return `200` instead of `202` for SUBSCRIBE by default (RFC6665)
40 |
41 | #### siputils
42 |
43 | - removed `ring_insert_callid()` function (see: )
44 |
45 | #### uac_redirect
46 |
47 | - `acc_function` mod param has to be set to empty string to disable binding to `acc` module
48 |
49 | ### Removed Modules
50 |
51 | - none
52 |
53 | ### Renamed Modules
54 |
55 | - `malloc_test` - replaced by `misctest` (`UPG`)
56 |
57 | ## Internal Libraries
58 |
59 | ## Core
60 |
61 | - intensive C code fuzzing and static analysis were performed which resulted in
62 | adding stricker checks for input values. That can cause change in behaviour
63 | for some variables or transformations. For example, `{s.int}` checks that
64 | the value is in between INT_MIN and INT_MAX.
65 |
66 | ### Parameters
67 |
68 | #### Dst Blocklist Parameters
69 |
70 | (`UPG`)
71 |
72 | All global parameters related to dst blocking are now using blocklist
73 | instead of blacklist in the name, see:
74 |
75 | - [Core Cookbook](../../cookbooks/5.6.x/core.md#blocklist_parameters)
76 |
77 | For example, **use_dst_blacklist** used in older versions has to be
78 | replaced by **use_dst_blocklist**.
79 |
80 | ### Misc
81 |
82 | ## Database
83 |
84 | ### MySQL Database Structure
85 |
86 | The following changes were done to the database tables existing in v5.5.x:
87 |
88 | - (`INF`, `RCM`) index was created on column `connection_id` for table `location` of `usrloc` module
89 | - (`UPG`) type of column `protocol` for table `location` of `ims_usrloc_pcscf` module was changed from `char(5)` to `int(10)` (used only for IMS deployments)
90 |
91 | Run following SQL statements in MySQL client to upgrade database
92 | structure from v5.5 to v5.6:
93 |
94 | ``` sql
95 | -- add index on connection_id for usrloc module location table
96 | CREATE INDEX tcpcon_idx ON location (`connection_id`);
97 | ```
98 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.6.x-to-5.7.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.6.x to v5.7.0
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of `v5.7.0` compared with what existed
5 | in `v5.6.x`. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from `v5.6.x` to run with Kamailio
7 | `5.7.0`.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.5.x to v5.6.0](5.5.x-to-5.6.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - `INF` - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - `CPM` - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - `RCM` - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - `UPG` - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | - `app_ruby` needs `app_ruby_proc` which is loaded automatically when found
34 | - INF: the `tls` and `tlsa` in v5.7.0 modules do not support openssl (libssl) 3.0, they have to be linked with openssl (libssl) 1.1 or 1.0. Since v5.7.1, tls and tlsa should be compatible with openssl (libssl) 3.0. Note also the availability of `tls_wolfssl` module.
35 |
36 | ### Removed Modules
37 |
38 | - none
39 |
40 | ### Renamed Modules
41 |
42 | ## Internal Libraries
43 |
44 | ## Core
45 |
46 | - INF: new core parameter `return_mode` allows a new mode to evaluate the return codes from functions and routing blocks:
47 | -
48 |
49 | ### Parameters
50 |
51 | ### Misc
52 |
53 | ## Database
54 |
55 | ### MySQL Database Structure
56 |
57 | New index was created for `watchers` table.
58 |
59 | ```sql
60 | CREATE INDEX time_status_idx ON watchers (`inserted_time`, `status`);
61 | ```
62 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.7.x-to-5.8.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.7.x to v5.8.0 (stable)
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v5.8.0 compared with what existed
5 | in v5.7.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v5.7.x to run with Kamailio
7 | 5.8.0.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.6.x to v5.7.0](5.6.x-to-5.7.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - UPG - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | - none
34 |
35 | ### Archived Modules
36 |
37 | - app_sqlang
38 | - auth_identity
39 |
40 | Archived modules can be found in the repository:
41 |
42 | -
43 |
44 | ### Renamed Modules
45 |
46 | - none
47 |
48 | ## Internal Libraries
49 |
50 | ## Core
51 |
52 | ### Parameters
53 |
54 | ### Misc
55 |
56 | ## Database
57 |
58 | ### MySQL Database Structure
59 |
60 | There is no change in the database structure used for 5.7.x series that has to
61 | be done in order to run same config with 5.8.x series.
62 |
--------------------------------------------------------------------------------
/docs/install/upgrade/5.8.x-to-6.0.0.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.8.x to v6.0.0 (stable)
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v6.0.0 compared with what existed
5 | in v5.8.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v5.8.x to run with Kamailio
7 | 6.0.0.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.7.x to v5.8.0](5.7.x-to-5.8.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - UPG - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | - **app_python3**
34 | * removed legacy exported modules to Python, use instead the KEMI `KSR` modules
35 |
36 | - **dialog**
37 | * dropped support for dlg_flag parameter
38 |
39 | ### Removed Modules
40 |
41 | - see the section about `Archived Modules`
42 |
43 | ### Renamed Modules
44 |
45 | - none
46 |
47 | ## Internal Libraries
48 |
49 | ## Core
50 |
51 | ### Parameters
52 |
53 | ### Misc
54 |
55 | ## Database
56 |
57 | ### MySQL Database Structure
58 |
59 | Run following SQL statements in MySQL client to upgrade database
60 | structure from v5.8 to v6.0:
61 |
62 | ``` sql
63 | ALTER TABLE htable CHANGE COLUMN `key_name` `key_name` VARCHAR(256) DEFAULT '' NOT NULL; -- # was VARCHAR(64) DEFAULT '' NOT NULL
64 | ALTER TABLE htable CHANGE COLUMN `key_value` `key_value` VARCHAR(512) DEFAULT '' NOT NULL; -- # was VARCHAR(128) DEFAULT '' NOT NULL
65 | ```
66 |
--------------------------------------------------------------------------------
/docs/install/upgrade/stable-to-devel.md:
--------------------------------------------------------------------------------
1 | # Upgrade Kamailio from v5.8.x to v5.9.0 (devel)
2 |
3 | The page contains the details about the changes that were made to old
4 | components during the development of v5.7.0 compared with what existed
5 | in v5.6.x. It does not include the brand new modules, focusing on how to
6 | upgrade database and configuration file from v5.6.x to run with Kamailio
7 | 5.7.0.
8 |
9 | ## Previous Stable Release
10 |
11 | If you look for the guidelines to upgrade to previous stable release,
12 | see:
13 |
14 | - [Upgrade Kamailio v5.7.x to v5.8.0](5.7.x-to-5.8.0.md)
15 |
16 | ## Remarks
17 |
18 | Following tokens are used to mark the changes:
19 |
20 | - INF - the change doesn't really have any direct impact - no action
21 | required in old config
22 | - CPM - the change was used with the new value via explicit parameter
23 | in default config file from old releases
24 | - RCM - the change is recommended to be done if you had an explicit
25 | different or lower value for this parameter in old config
26 | - UPG - the change has to be done, older config does not work any
27 | longer
28 |
29 | ## Modules
30 |
31 | ### Upgraded Modules
32 |
33 | - none
34 |
35 | ### Removed Modules
36 |
37 | - none
38 |
39 | ### Renamed Modules
40 |
41 | - none
42 |
43 | ## Internal Libraries
44 |
45 | ## Core
46 |
47 | ### Parameters
48 |
49 | ### Misc
50 |
51 | ## Database
52 |
53 | ### MySQL Database Structure
54 |
55 | Run following SQL statements in MySQL client to upgrade database
56 | structure from v5.8 to v5.9:
57 |
58 | ``` sql
59 | ...
60 | ```
61 |
--------------------------------------------------------------------------------
/docs/kemi/performances.md:
--------------------------------------------------------------------------------
1 | # KEMI Performances
2 |
3 | This page collects details about performance results for KEMI
4 | interpreters as well as tips and tricks to increase the processing
5 | capacity when using KEMI.
6 |
7 | ## Performance Tests
8 |
9 | - [KEMI Performance Tests For v5.2.x](../kemi/performance-tests/5.2.x.md)
10 |
11 | ## Tips And Tricks
12 |
13 | ### Variables
14 |
15 | With some scripting languages such as Lua it was observed that is better
16 | to store the value of a Kamailio pseudo-variables inside a local
17 | variable if used many times. For example:
18 |
19 | ``` lua
20 | if KSR.corex.has_user_agent() then
21 | local K_ua = KSR.pv.gete("$ua");
22 | if string.find(K_ua, "friendly-scanner")
23 | or string.find(K_ua, "sipcli") then
24 | KSR.sl.sl_send_reply(200, "OK");
25 | KSR.x.exit();
26 | end
27 | end
28 | ```
29 |
--------------------------------------------------------------------------------
/docs/old-releases/packages/debs.md:
--------------------------------------------------------------------------------
1 | # DEB Packages
2 |
3 | Starting from March 3, 2014 [Sipwise Team](http://www.sipwise.com)
4 | provides a **Kamailio DEB repository** for Debian and Ubuntu
5 | distributions.
6 |
7 | Sporadically, Debian packages may be available via OpenSuse Build
8 | Service (OBS), see details in a dedicated sub-section.
9 |
10 | ## Instructions
11 |
12 | First download and add our GPG key to your apt key list:
13 |
14 | wget -O- https://deb.kamailio.org/kamailiodebkey.gpg | sudo apt-key add -
15 |
16 | Our GPG key fingerprint is
17 | `E79A CECB 87D8 DCD2 3A20 AD2F FB40 D3E6 508E A4C8` - make sure you
18 | verify it and check it in a key store before trusting it.
19 |
20 | Then add the repository lines to your `/etc/apt/sources.list` file
21 | depending on the Kamailio version of your choice:
22 |
23 | The list of APT repositories and associated operating systems is
24 | available at:
25 |
26 | - ****
27 |
28 | ## Using OBS Repository
29 |
30 | ### Status
31 |
32 | **Important: not actively maintained, use it only if you need to install
33 | older versions of Kamailio!!!**
34 |
35 | OBS Project:
36 |
37 | -
38 |
39 | Download Repositories:
40 |
41 | -
42 | -
43 | -
44 | -
45 | -
46 |
47 | #### Overview
48 |
49 | - No source packages
50 | - No nightly builds
51 |
52 | #### Kamailio v4.1.x
53 |
54 | - Distributions: `Debian 6.0 Squeeze`, `Debian 7.0 Wheezy`,
55 | `Ubuntu 12.04 Precise`
56 | - Archs supported: `amd64`, `i386`
57 |
58 | #### Kamailio v3.2.x
59 |
60 | - Distributions: `Debian 5.0 Lenny`, `Debian 6.0 Squeeze`,
61 | `Ubuntu 10.04 Lucid`
62 | - Archs supported: `amd64`, `i386`
63 |
64 | ### APT Key
65 |
66 | First download and add our GPG key to your apt key list:
67 |
68 | wget https://api.opensuse.org/source/home:kamailio/_pubkey
69 | apt-key add _pubkey
70 |
71 | Select from next list the repository URLs specific for desired Kamailio
72 | version and Operating System and add to your `/etc/apt/sources.list`.
73 |
74 | ### APT Repositories for Kamailio v4.1.x
75 |
76 | #### `Debian Squeeze`
77 |
78 | deb http://download.opensuse.org/repositories/home:/kamailio:/telephony-debs/Debian_6.0 ./
79 |
80 | #### `Debian Wheezy`
81 |
82 | deb http://download.opensuse.org/repositories/home:/kamailio:/telephony-debs/Debian_7.0 ./
83 |
84 | #### `Ubuntu Precise`
85 |
86 | deb http://download.opensuse.org/repositories/home:/kamailio:/telephony-debs/xUbuntu_12.04 ./
87 |
88 | ### APT Repositories for Kamailio v3.2.x
89 |
90 | #### `Debian Lenny`
91 |
92 | deb http://download.opensuse.org/repositories/home:/kamailio:/telephony-debs/Debian_5.0 ./
93 |
94 | #### `Debian Squeeze`
95 |
96 | deb http://download.opensuse.org/repositories/home:/kamailio:/telephony-debs/Debian_6.0 ./
97 |
98 | #### `Ubuntu Lucid`
99 |
100 | deb http://download.opensuse.org/repositories/home:/kamailio:/telephony-debs/xUbuntu_10.04 ./
101 |
102 | ### APT Repositories Remarks
103 |
104 | **Important note**: apt may throw error, since **download.opensuse.org**
105 | can return 302 reply to redirect to a mirror. You have to update the URL
106 | in **sources.list** to use directly a mirror server. For that:
107 |
108 | - find a mirror - based on your OS, browse:
109 | -
110 | -
111 | -
112 | -
113 | -
114 | - pick one of the mirrors listed in the browsed page, for example
115 | **widehat.opensuse.org**, select its listed URL and add to
116 | **sources.list** the URL without the last "/Packages", resulting in:
117 | -
118 | -
119 | -
120 |
--------------------------------------------------------------------------------
/docs/packages/alpinelinux.md:
--------------------------------------------------------------------------------
1 | # AlpineLinux Packages
2 |
3 | Kamailio packages are now available for AlpineLinux
4 |
5 | Package Info:
6 |
7 | - [x86](https://pkgs.alpinelinux.org/packages?name=kamailio*&branch=edge&repo=mainarch=x86)
8 | - [x86_64](https://pkgs.alpinelinux.org/packages?name=kamailio*&branch=edge&repo=mainarch=x86_64)
9 |
--------------------------------------------------------------------------------
/docs/playground/playground.md:
--------------------------------------------------------------------------------
1 | # PlayGround
2 |
--------------------------------------------------------------------------------
/docs/scripts/toc.md:
--------------------------------------------------------------------------------
1 | # Various Scripts
2 |
3 | - [Basic SDP parser to use with app_python module](../scripts/python/sdp-parser.md)
4 |
--------------------------------------------------------------------------------
/docs/security/policy.md:
--------------------------------------------------------------------------------
1 | # Security Vulnerability Policy
2 |
3 | References:
4 |
5 | - [Asterisk security process](https://wiki.asterisk.org/wiki/display/AST/Asterisk+Security+Vulnerabilities)
6 | - [Wikipedia reference for vulnerabilities](https://en.wikipedia.org/wiki/Vulnerability_(computing))
7 |
8 | ## Definition
9 |
10 | A security vulnerability is (for example) when a user of Kamailio can
11 | cause Kamailio to crash or lock up by sending messages to the server
12 | process.
13 |
14 | ## Reporting a security Vulnerability
15 |
16 | If you believe there's a security vulnerability, please don't use the
17 | public forums. Send an e-mail to the security team and the issue will be
18 | handled properly.
19 |
20 | 1. Send an e-mail to **security at kamailio dot org** and include the
21 | following information
22 |
23 |
24 |
25 | * A summary
26 | * A detailed explanation of how this issue can be exploited and/or reproduced
27 | - A member of the Kamailio Security Team will respond
28 | - The kamailio developer team will work to solve the issue.
29 | - When there is a patch for the issue, it should NOT be committed directly without clarification with the security team. In many cases this should be coordinated with the release of a security release as well as the publication of a Kamailio project security vulnerability report.
30 |
31 | ## Publishing security vulnerabilities
32 |
33 | Kamailio will publish security vulnerabilities, including an CVE ID, on
34 | the kamailio-business mailing list, sr-dev, sr-users as well as related
35 | lists. The advisories will also be published on the kamailio.org web
36 | site. This will be done for vulnerabilities that have a higher severity,
37 | that means having a big enough impact as decided from the Kamailio
38 | Security Team.
39 |
40 | CVE entries should be created for critical vulnerabilities in the core
41 | and major modules, for rarely used modules this is not necessary. If
42 | there are several security issues together in one release, they should
43 | be announced together.
44 |
45 | The Kamailio project release security fixed in the normal time based
46 | maintenance schedule, no immediate security releases are done. If
47 | possible a non-code workaround should be provided for the found security
48 | vulnerability.
49 |
50 | ## Timeline of the security process
51 |
52 | 1. Initial acknowledge time to the reporting party for a report about a
53 | new security issue for a new report: 3 working days
54 | 2. Time for verification and bug fix from Kamailio development: 5
55 | working days (could be extended e.g. in vacation period)
56 | 3. Waiting time for public announcement after the fix is in an official
57 | release: 2 months
58 | 4. Project preparation time for kamailio.org announcement: 3 working
59 | days
60 |
61 | ## Kamailio Security Team
62 |
63 | A Kamailio Security team is appointed with core developers of the
64 | project. These individuals will be part of the security process and
65 | review patches and text for the vulnerability report. Persons of this
66 | group take the role of Kamailio Security Officers. One of these should
67 | manage each security incident - which does not mean solving the code
68 | issue, but managing the process from report to publication and patch
69 | release.
70 |
71 | ## PGP encryption
72 |
73 | The address used for reporting security reports to the Kamailio project
74 | should have a PGP key associated, used by the security officers.
75 |
--------------------------------------------------------------------------------
/docs/sidebar.md:
--------------------------------------------------------------------------------
1 | # sidebar
2 |
3 | - [Wiki Home](index.md)
4 | - [Kamailio Site](https://www.kamailio.org)
5 | - [Docs Index](https://www.kamailio.org/docs/)
6 | - [Modules Docs](https://www.kamailio.org/docs/modules/)
7 | - [Old Wiki For v4.3.x+](https://www.kamailio.org/wiki/)
8 | - [Old Wiki For v4.2.x-](https://www.kamailio.org/dokuwiki/)
9 | - [Old Wiki](https://www.kamailio.org/dokuwiki/)
10 | - [Github Markdown Syntax](https://github.github.com/gfm/)
11 |
--------------------------------------------------------------------------------
/docs/tutorials/3.2.x/syslog.md:
--------------------------------------------------------------------------------
1 | # Kamailio with Syslog and Log Rotate
2 |
3 | ```
4 | Authors of initial tutorial:
5 | Daniel-Constantin Mierla
6 |
7 |
8 | Elena-Ramona Modroiu
9 |
10 | ```
11 |
12 | How-to about configuring syslog daemon to write the log messages from
13 | Kamailio SIP server in a dedicated file and rotate it when becomes too
14 | big.
15 |
16 | This tutorial is updated for Kamailio v3.2.0 or newer (original tutorial
17 | written for [older versions is here](http://www.kamailio.org/dokuwiki/doku.php/tutorials:debug-syslog-messages)).
18 |
19 | ## Syslog - Custom Log File
20 |
21 | In a Linux/Unix environment it is possible to configure syslog to write
22 | log messages to a separate file for a specific facility.
23 |
24 | Also Kamailio can be configured to use a particular facility and
25 | therefore then make syslog to redirect that facility into a separate
26 | file. This can greatly improve the readability and manageability of
27 | Kamailio logs.
28 |
29 | The default syslog file depends on your OS distribution. For example, in
30 | Debian/Ubuntu is `/var/log/syslog` and in RedHat/CentOS/Fedora is
31 | `/var/log/messages`. To make Kamailio print log messages in another file
32 | you have to follow the next instructions.
33 |
34 | - set option `log_facility=LOG_LOCAL0` in Kamailio configuration file
35 | (this is in the default Kamailio config)
36 | - then configure syslog to use a special file for log messages with
37 | facility `LOG_LOCAL0`
38 |
39 | The configuration file of syslog can be usually found in
40 | `/etc/syslog.conf`. Next example, `Changes in syslog.conf` shows a
41 | syslog configuration file modified to report Kamailio error messages
42 | into a separate file.
43 |
44 | Example: `Changes in syslog.conf`
45 |
46 | ```
47 | ...
48 | #
49 | # don't log messages with LOG_LOCAL0 in /var/log/syslog anymore
50 | *.*;auth,authpriv.none,local0.none -/var/log/syslog
51 |
52 | #
53 | # log messages with LOG_LOCAL0 in /var/log/kamailio.log
54 | local0.* -/var/log/kamailio.log
55 | ...
56 | ```
57 |
58 | NOTE: The `-` in front of `/var/log/kamailio.log` is to skip
59 | synchronizing the log file after every log message. If you choose to
60 | configure `syslog` in synchronous mode you must be aware that it has big
61 | impact over performances when the signaling traffic is high.
62 |
63 | ## Syslog-NG Configuration
64 |
65 | If you are using **syslogn-ng**, one of the options you can add in its
66 | configuration file is:
67 |
68 | ```
69 | destination local0 { file("/var/log/kamailio.log"); };
70 | filter f_local0 { facility(local0); };
71 | log { source(src); filter(f_local0); destination(local0); };
72 | ```
73 |
74 | ## Log Rotate
75 |
76 | When using **syslog** daemon, in most of current Linux distributions,
77 | you just have to add a file:
78 |
79 | ```
80 | /etc/logrotate.d/kamailio
81 | ```
82 |
83 | Containing:
84 |
85 | ```
86 | /var/log/kamailio.log {
87 | missingok
88 | size=50M
89 | create 0644 root root
90 | postrotate
91 | /bin/kill -HUP `cat /var/run/syslogd.pid 2> /dev/null` 2> /dev/null || true
92 | endscript
93 | }
94 | ```
95 |
96 | Otherwise, add the piece of config above in **/etc/logrotate.conf**.
97 |
98 | For **syslog-ng** the appropriate pid file has to be used, should be
99 | like:
100 |
101 | ```
102 | /var/log/kamailio.log {
103 | missingok
104 | size=50M
105 | create 0644 root root
106 | postrotate
107 | /bin/kill -HUP `cat /var/run/syslog-ng.pid 2> /dev/null` 2> /dev/null || true
108 | endscript
109 | }
110 | ```
111 |
112 | You can test the existence of pid files before using kill, like:
113 |
114 | ```
115 | if [ -f /var/run/syslog-ng.pid ]; then \
116 | kill -HUP `cat /var/run/syslog-ng.pid`; \
117 | fi;
118 | ```
119 |
120 | For **rsyslogd**:
121 |
122 | ```
123 | /var/log/kamailio.log {
124 | daily
125 | missingok
126 | rotate 14
127 | compress
128 | delaycompress
129 | create 0644 root adm
130 | postrotate
131 | /usr/lib/rsyslog/rsyslog-rotate
132 | endscript
133 | }
134 | ```
135 |
--------------------------------------------------------------------------------
/docs/tutorials/auth/auth_db.md:
--------------------------------------------------------------------------------
1 | # auth_db
2 |
3 | **Note: This document is work in progress and yet unfinished!**
4 |
5 | written by Emmanuel Schmidbauer ()
6 |
7 | This guide is designed to illustrate how to setup auth_db and usrloc to
8 | do digest authentication using a database backend. I will be using a
9 | postgresql database in this example.
10 |
11 | The following modules are required: usrloc, registrar, auth, auth_db
12 |
13 | # General preparations
14 |
15 | You'll probably want to setup your database and add a few users. I will
16 | briefly go over how to setup the tables using the schema provided with
17 | kamailio.
18 |
19 | # Modules: auth, auth_db, usrloc, registrar
20 |
21 | ``` c
22 | loadmodule "auth.so"
23 | loadmodule "auth_db.so"
24 | loadmodule "usrloc.so"
25 | loadmodule "registrar.so"
26 |
27 | modparam("auth_db|usrloc", "db_url", DB_URL)
28 | modparam("auth_db", "use_domain", 1)
29 | modparam("auth_db", "calculate_ha1", 1)
30 | modparam("usrloc", "db_mode", 3 )
31 | modparam("usrloc", "desc_time_order", 1 )
32 | modparam("usrloc", "nat_bflag", 1 )
33 | modparam("usrloc", "timer_interval", 5 )
34 | modparam("usrloc", "use_domain", 1)
35 | modparam("nathelper|registrar", "received_avp", "$avp(s:rcv)")
36 |
37 | # ------------------------- request routing logic -------------------
38 | # main routing logic
39 |
40 | route {
41 | # per request initial checks
42 | route(SANITY_CHECK);
43 |
44 | # CANCEL processing
45 | if (is_method("CANCEL")) {
46 | if (t_check_trans()) {
47 | t_relay();
48 | }
49 | exit;
50 | }
51 |
52 | route(CHECK_SOURCE_IP);
53 |
54 | ##################################
55 | ### HANDLE SEQUENTIAL REQUESTS ###
56 | route(WITHINDLG);
57 |
58 | ###############################
59 | ### HANDLE INITIAL REQUESTS ###
60 | t_check_trans();
61 |
62 | route(REGISTER);
63 |
64 | route(INVITE);
65 |
66 | route(RELAY);
67 | }
68 |
69 | route[REGISTER]
70 | {
71 | if (is_method("REGISTER")) {
72 | # auth user/pass
73 | if(!www_authenticate("$fd", "user_extension")) {
74 | www_challenge("$fd", "1");
75 | }
76 |
77 | if (!save("sip_registration")) {
78 | sl_reply_error();
79 | }
80 | exit;
81 | }
82 |
83 | }
84 |
85 | # Handle INVITE + REFER
86 | route[INVITE]
87 | {
88 | # record routing for dialog forming requests (in case they are routed)
89 | # remove preloaded route headers
90 | remove_hf("Route");
91 | if (is_method("INVITE|REFER")) {
92 | record_route();
93 | # auth user/pass
94 | if (!proxy_authenticate("$fd", "user_extension")) {
95 | proxy_challenge("$fd", "1");
96 | exit;
97 | }
98 | }
99 | }
100 | ```
101 |
--------------------------------------------------------------------------------
/docs/tutorials/cmake/commands.md:
--------------------------------------------------------------------------------
1 |
2 | # Old-Makefiles And CMake Commands
3 |
4 | [Building Kamailio From Source Using CMake - ToC](index.md)
5 |
6 | The corresponding or similar commands between the old build systems using Makefiles
7 | and the new one using CMake.
8 |
9 | The Old-Makefiles commands are run in the root folder of Kamailio source code:
10 |
11 | ```
12 | cd /path/to/kamailio
13 | ```
14 |
15 | The CMake commands have to be run after:
16 |
17 | ```
18 | cd /path/to/kamailio
19 | mkdir build
20 | cd build
21 | ```
22 |
23 | Also, if `cmake` is in the example command, it usually has to be followed by
24 | `make` to perform the compilation.
25 |
26 | Legend for the table:
27 |
28 | - `OM` - Old-Makefiles
29 | - `CM` - CMake
30 |
31 | | Type | Description / Command |
32 | | :--- | :--- |
33 | | `---` | Generate config files for the build system |
34 | | `OM` | `make cfg` |
35 | | `CM` | `cmake ..` |
36 | | `---` | Specify installation path prefix |
37 | | `OM` | `make PREFIX=/tmp/kamailio-dev cfg` |
38 | | `CM` | `cmake -DCMAKE_INSTALL_PREFIX=/tmp/kamailio-dev ..` |
39 | | `---` | Specify additional modules to be included in compilation |
40 | | `OM` | `make include_modules="app_lua db_mysql" cfg` |
41 | | `CM` | `cmake -DINCLUDE_MODULES="app_lua db_mysql" ..` |
42 | | `---` | Specify modules to be excluded from compilation |
43 | | `OM` | `make exclude_modules="app_lua db_mysql" cfg` |
44 | | `CM` | `cmake -DEXCLUDE_MODULES="app_lua db_mysql" ..` |
45 | | `---` | Compile `kamailio` binary (the core) |
46 | | `OM` | `make` |
47 | | `CM` | `make kamailio` |
48 | | `---` | Compile everything (core and modules) |
49 | | `OM` | `make all` |
50 | | `CM` | `make` |
51 | | `---` | Compile `acc` modules (substitute with any other module name) |
52 | | `OM` | `make modules modules=src/modules/acc` |
53 | | `CM` | `make acc` |
54 | | `---` | Compile with verbose output (quiet off) |
55 | | `OM` | `make Q=0` |
56 | | `CM` | `make VERBOSE=on` |
57 | | `---` | Specify the compiler (example with `clang`) |
58 | | `OM` | `make CC=clang` |
59 | | `CM` | `cmake -DCMAKE_C_COMPILER="clang" ..` |
60 |
--------------------------------------------------------------------------------
/docs/tutorials/cmake/default.md:
--------------------------------------------------------------------------------
1 | # The Basics Of Building Kamailio From Source Using CMake
2 |
3 | [Building Kamailio From Source Using CMake - ToC](index.md)
4 |
5 | This guide will walk you through the process of building Kamailio from source using CMake.
6 |
7 | ## Prerequisites
8 |
9 | Before you begin, ensure you have the following installed:
10 |
11 | For building core Kamailio:
12 |
13 | - Git
14 | - CMake (version 3.10 or higher)
15 | - GCC (GNU Compiler Collection)
16 | - Bison and Flex (for parsing)
17 |
18 | For additional features (CMake will error or warn if a library is not found):
19 |
20 | - MySQL or PostgreSQL (for database support) (optional)
21 | - OpenSSL (for TLS support) (optional)
22 | - libxml2 (for XML support) (optional)
23 | - many more (check each module's documentation for specific requirements)
24 |
25 | ## Building Kamailio
26 |
27 | 1. Clone the Kamailio repository from GitHub:
28 |
29 | ```bash
30 | git clone https://github.com/kamailio/kamailio.git
31 | ```
32 |
33 | 2. Navigate to the Kamailio directory:
34 |
35 | ```bash
36 | cd kamailio
37 | ```
38 |
39 | ### Using CMake commands
40 |
41 | 3. Create the build directory if it doesn't exist and cofigure the project:
42 |
43 | ```bash
44 | cmake -S . -B build # `-S .` where is the CMakeLists.txt file, `-B build` where to put the build files
45 | ```
46 |
47 | 4. Build the project:
48 |
49 | ```bash
50 | cmake --build build
51 | ```
52 |
53 | 5. Install the project:
54 |
55 | ```bash
56 | sudo cmake --install build
57 | ```
58 |
59 | ### Or using make commands
60 |
61 | 3. Create a build directory (you can name it whatever you want) and navigate to it:
62 |
63 | ```bash
64 | mkdir build
65 | cd build
66 | ```
67 |
68 | 4. Run CMake to generate the build files:
69 |
70 | ```bash
71 | cmake ..
72 | ```
73 |
74 | 5. Build the project:
75 |
76 | ```bash
77 | make
78 | ```
79 |
80 | 6. Install the project:
81 |
82 | ```bash
83 | sudo make install
84 | ```
85 |
86 | Kamailio should now be installed on your system (default path is `/usr/local/sbin/kamailio`).
87 |
88 | You can start it using the following command: (you may need to use `sudo` if you installed it in a system directory and use system files)
89 |
90 | ```bash
91 | kamailio -f /usr/local/etc/kamailio/kamailio.cfg
92 | ```
93 |
94 | Congratulations! You have successfully built and installed Kamailio from source using CMake.
95 |
--------------------------------------------------------------------------------
/docs/tutorials/cmake/index.md:
--------------------------------------------------------------------------------
1 |
2 | # Building Kamailio From Source Using CMake
3 |
4 | Tutorials for building Kamailio using CMake.
5 |
6 | * [The Basics Of Building Kamailio From Source Using CMake](default.md)
7 |
8 | * [Customizing The Building Kamailio With CMake Options](custom.md)
9 |
10 | * [Corresponding Old-Makefiles And CMake Commands](commands.md)
11 |
12 | * [Available Targets](targets.md)
13 |
--------------------------------------------------------------------------------
/docs/tutorials/cmake/targets.md:
--------------------------------------------------------------------------------
1 | # Kamailio Available Targets
2 |
3 | This document lists all available targets for Kamailio with CMake, providing a brief description of each.
4 |
5 | Use `make target_name` to execute the desired target in the build folder.
6 |
7 | ## Build Targets
8 |
9 | - **all**: Builds all components (core and modules) of Kamailio.
10 | - **clean**: Cleans up the build directory by removing all generated files.
11 | - **GenerateParser**: Generates the configuration parser source files from the configuration parser grammar files.
12 | - **kamailio**: Builds the Kamailio core.
13 | - **modules**: Builds all the enabled modules.
14 | + ****: Compile module with name `module_name`, ie `make acc` for `acc` module.
15 |
16 | - **kamctl**: Builds the `kamctl` utility, which is used for managing Kamailio configurations. (even though kamctl does not require building, there are some config files that are generated during the build process)
17 | - **kamdbctl**: Builds the `kamdbctl` utility, which is used for managing Kamailio databases. (even though kamdbctl does not require building, there are some config files that are generated during the build process)
18 | - **kamcmd**: Builds the `kamcmd` utility.
19 | - **dbschema**: Generates the database schema for all databases used by Kamailio that are enabled in the configuration (`db_*` modules). **Note**: This target is NOT included in the default `all` target. You need to run it separately. If you want to install the schema, make sure to build it first.__
20 | + **dbschema_**: Generates the database schema for a specific database. Replace `` with the actual database name, such as `mysql`, `postgres`, `db_berkeley`, etc. See kamctl folder structure for exact naming.
21 | + **dbschema__clean**: Cleans up the database schema for a specific database. Replace `` with the actual database name, such as `mysql`, `postgres`, `db_berkeley`, etc. See kamctl folder structure for exact naming.
22 | - **dbschema_clean**: Cleans up the database schema for all databases used by Kamailio that are enabled in the configuration (`db_*` modules).
23 |
24 | ## Install Targets
25 |
26 | - **install**: Installs the built components to the specified directory.
27 | - **uninstall**: Uninstalls the previously installed components.
28 | - **install-kamailio-utils**: Installs the Kamailio utilities (`kamctl` and `kamdbctl`) and kamailio congiguration files.
29 | + **install-kamailio-utils-bin**: Installs the Kamailio utilities binaries (kamctl kamdbctl).
30 | + **install-kamailio-utils-cfg**: Installs the Kamailio utilities configuration files (kamctlrc kamailio.cfg).
31 | - **install_kamailio_docs**: Installs the Kamailio documentation.
32 |
33 | ## Documentation Targets
34 |
35 | - **kamailio_docs**: Generates the documentation for Kamailio and it's modules.
36 | + **_doc**: Generates the documentation for a specific module. Replace `module_name` with the actual module name.
37 | * **_doc_text**: Generates the documentation for a specific module in text format.
38 | * **_doc_html**: Generates the documentation for a specific module in HTML format.
39 | * **_readme**: Generates the documentation for a specific module in README format in the source code tree of each module.
40 | - **kamailio_docs_man**: Generates the man pages for ALL modules.
41 | + **_man**: Generates the man page for a specific module if available. Replace `module_name` with the actual module name.
42 | - **kamailio_docs_readme**: Generates the documentation for ALL modules in README format in the source code tree of each module. _Note: This will overwrite the existing README files._
43 |
44 | - **man**: Creates the manual pages for Kamailio core and utils.
45 | + **kamctl_man**: Creates the manual page for the `kamctl` and `kamdbctl` utils.
46 | + **kamdcmd_man**: Creates the manual page for the `kamcmd`util.
47 |
--------------------------------------------------------------------------------
/docs/tutorials/kamailio-and-mongodb.md:
--------------------------------------------------------------------------------
1 | # Kamailio and MongoDB
2 |
3 | Details about how to use Kamailio with a MongoDB backend.
4 |
5 | ## Kamailio Database
6 |
7 | The **use** command in mongodb client **mongo** creates the database if
8 | it doesn't exit:
9 |
10 | # mongo
11 | > use kamailio
12 |
13 | To display the databases, you can use:
14 |
15 | > show dbs
16 |
17 | Note that a database is not shown by the above command if it is empty --
18 | you need to add some records to it.
19 |
20 | ### Version Table
21 |
22 | Kamailio uses version table to check if the structure of a database
23 | table has the structure version the C code expects.
24 |
25 | A table is MongoDB is named collection. To create the collection
26 | **version**, do:
27 |
28 | > db.createCollection("version")
29 |
30 | List the existing collections in the current database:
31 |
32 | > show collections
33 | system.indexes
34 | version
35 | >
36 |
37 | #### Version Table Records
38 |
39 | Add the records for the other Kamailio tables you are going to use. Some
40 | examples:
41 |
42 | > db.getCollection("version").insert({table_name: "subscriber", table_version: NumberInt(6) })
43 |
44 | > db.getCollection("version").insert({table_name: "location", table_version: NumberInt(8) })
45 |
46 | > db.getCollection("version").insert({table_name: "presentity", table_version: NumberInt(4) })
47 |
48 | > db.getCollection("version").insert({table_name: "watchers", table_version: NumberInt(3) })
49 |
50 | > db.getCollection("version").insert({table_name: "active_watchers", table_version: NumberInt(11) })
51 |
52 | To learn what is the version number for a specific table, look inside
53 | **lib/srdb1/schema/**, there is an xml file with the name of the table
54 | and inside it you should see the **version** attribute.
55 |
56 | ### Other Tables
57 |
58 | MongoDB doesn't have a schema definition for documents stored in a
59 | collection. It is not required to create a collection before inserting a
60 | record to it.
61 |
62 | Anyhow, if you want, you can create the collections in advance, using:
63 |
64 | > db.createCollection("tablename")
65 |
66 | ## Kamailio Config
67 |
68 | ### DB URL
69 |
70 | You need to load the "db_mongodb" module in the configuration.
71 |
72 | The corresponding database URL in kamailio.cfg:
73 |
74 | - if MongoDB is on local host and there is no username and password to
75 | connect to it:
76 |
77 |
78 |
79 | #!define DBURL "mongodb://localhost/kamailio"
80 |
81 | - if MongoDB is on local host and there is a username and password to
82 | connect to it:
83 |
84 |
85 |
86 | #!define DBURL "mongodb://username:password@localhost/kamailio"
87 |
88 | ### Other Parameters
89 |
90 | If you store location records in MongoDB, set the following parameter
91 | for usrloc modules:
92 |
93 | modparam("usrloc", "db_insert_null", 1)
94 |
--------------------------------------------------------------------------------
/docs/tutorials/kamailio-startup-scripts.md:
--------------------------------------------------------------------------------
1 | # Kamailio Startup Scripts
2 |
3 | A collection with useful details about startup scripts for various
4 | Operating Systems.
5 |
6 | ## CentOS 7 With Systemd
7 |
8 | Content of **/etc/systemd/kamailio.service**"
9 |
10 | [Unit]
11 | Description=Kamailio SIP Server
12 | Documentation=man:kamailio(8) http://www.kamailio.org/
13 | After=syslog.target network-online.target
14 |
15 | [Service]
16 | Type=forking
17 | User=kamailio
18 | Environment=SHM_SIZE=64
19 | Environment=PKG_SIZE=8
20 | ExecStartPre=/usr/sbin/kamailio -c
21 | ExecStart=/usr/sbin/kamailio -m $SHM_SIZE -M $PKG_SIZE \
22 | -P /run/kamailio/kamailio.pid
23 | ExecStopPost=/usr/bin/rm -f /run/kamailio/kamailio.pid
24 | PIDFile=/run/kamailio/kamailio.pid
25 | Restart=on-failure
26 | RestartSec=30
27 |
28 | [Install]
29 | WantedBy=multi-user.target
30 |
31 | Content of **/etc/tmpfiles.d/kamailio.conf**:
32 |
33 | d /run/kamailio 0750 kamailio kamailio
34 |
35 | ### Reload Systemd Units
36 |
37 | systemctl daemon-reload
38 | systemctl enable kamailio
39 | systemctl start kamailio
40 |
--------------------------------------------------------------------------------
/docs/tutorials/mini-howto-admin/call_forwarding.md:
--------------------------------------------------------------------------------
1 | # Call Forwarding
2 |
3 | ## Setup
4 |
5 | loadmodule "avpops.so"
6 | modparam("avpops","db_url","mysql://openser:openserrw@localhost/kamailio")
7 | modparam("avpops","avp_table","usr_preferences")
8 |
9 | ## Enable CF
10 |
11 | \*33 to enable:
12 |
13 | if ($rU=~"^\*33.*") {
14 | strip(3);
15 | avp_printf("$avp(s:fwd_blind)","$ruri");
16 | .......
17 | avp_db_delete("$from/username","$avp(s:fwd_blind)");
18 | avp_db_store("$from/username","$avp(s:fwd_blind)");
19 | sl_send_reply("404","CFWD Set");
20 | ....}
21 |
22 | ## Disable CF
23 |
24 | \*32 to disable:
25 |
26 | if ($rU=~"^\*32") {
27 | avp_db_delete("$from/username","$avp(s:fwd_blind)");
28 | sl_send_reply("404","CFWD UnSet");
29 | ...... }
30 |
31 | ## Forwarding
32 |
33 | if (avp_db_load("$ruri/username", "$avp(s:fwd_blind)")) {
34 | $from=$ruri;
35 | avp_pushto("$ruri", "$avp(s:fwd_blind)");
36 | ...
37 | route(RELAY);
38 | ....
39 |
--------------------------------------------------------------------------------
/docs/tutorials/mini-howto-admin/ldap-user-auth.md:
--------------------------------------------------------------------------------
1 | # User Authentication Using LDAP Backend
2 |
3 | Content is specific for Kamailio v4.0.x and OpenLDAP on a Debian/Ubuntu
4 | system.
5 |
6 | ## Prerequisites
7 |
8 | - install OpenLDAP library (libldap) v2.1 or greater, libldap header
9 | files (libldap-dev) are needed for compilation
10 | - read the documentation of auth module:
11 | -
12 | - read the documentation of ldap module:
13 | -
14 |
15 | ## LDAP Tree
16 |
17 | You have to store user profile attributes in LDAP tree. It is up to you
18 | to decide the structure, just have in mind that you have to store SIP
19 | password as a dedicated field and its value has to be plain text or HA1
20 | format.
21 |
22 | In this tutorial the example is with plain text SIP password stored in
23 | SIPPassword field. SIP username is stored in a dedicated field as well,
24 | namely SIPUserName. The SIP profiles are grouped under
25 | ou=sip,dc=example,dc=com.
26 |
27 | Next is an example of LDAP tree storing profiles for SIP subscribers.
28 |
29 | - dc=example,dc=com
30 | |
31 | +- ou=users
32 | | |
33 | | +- cn=sip_proxy -- sn: sip_proxy
34 | | -- userPassword: proxypwd
35 | |
36 | +- ou=sip
37 | |
38 | +- cn=user1 -- SIPUserName: user1
39 | | -- SIPPassword: pwd1
40 | |
41 | +- cn=user2 -- SIPUserName: user2
42 | -- SIPPassword: pwd2
43 |
44 | ## LDAP Module Configuration File
45 |
46 | It has to be stored in:
47 |
48 | - /usr/local/etc/kamailio/ldap.cfg
49 |
50 |
51 |
52 | [sipaccounts]
53 | ldap_server_url = "ldap://ldap.example.com"
54 | ldap_bind_dn = "cn=sip_proxy,ou=users,dc=example,dc=com"
55 | ldap_bind_password = "proxypwd"
56 |
57 | ## Kamailio Configuration File Snippet
58 |
59 | Parts of the config file to plug in your kamailio.cfg. route\[LDAPAUTH\]
60 | should replace route\[AUTH\] in default kamailio.cfg, but you may still
61 | need to take some bits from route\[AUTH\] and merge them in
62 | route\[LDAPAUTH\], up to what requirements you have for your routing
63 | authentication.
64 |
65 | ``` c
66 | ...
67 | loadmodule "ldap.so"
68 | ...
69 | modparam("ldap", "config_file", "/usr/local/etc/kamailio/ldap.cfg")
70 | ...
71 |
72 | route[LDAPAUTH] {
73 | if(!(is_present_hf("Authorization") || is_present_hf("Proxy-Authorization"))) {
74 | # no credentials header - send back challenge
75 | auth_challenge("$fd", "1");
76 | exit;
77 | }
78 |
79 | # do ldap search to fetch the password
80 | ldap_search("ldap://sipaccounts/ou=sip,dc=example,dc=com?SIPPassword?one?(cn=$fU)");
81 | $var(rc) = $rc;
82 | if ($var(rc)<0) {
83 | switch ($var(rc)) {
84 | case -1:
85 | # no LDAP entry found
86 | sl_send_reply("404", "User Not Found");
87 | exit;
88 | case -2:
89 | # internal error
90 | sl_send_reply("500", "Internal server error");
91 | exit;
92 | default:
93 | sl_send_reply("403", "Not allowed");
94 | exit;
95 | }
96 | }
97 | if(!ldap_result("SIPPassword/$avp(password)")) {
98 | sl_send_reply("404", "User Not Found");
99 | exit;
100 | }
101 | if (!pv_auth_check("$fd", "$avp(password)", "0", "1")) {
102 | auth_challenge("$fd", "1");
103 | exit;
104 | }
105 | # authentication ok - continue processing
106 |
107 | }
108 | ```
109 |
--------------------------------------------------------------------------------
/docs/tutorials/mini-howto-admin/main.md:
--------------------------------------------------------------------------------
1 | # Mini HowTo Guides for Kamailio Administration
2 |
3 | A collection of mini how-to tutorials addressing specific use cases of
4 | Kamailio.
5 |
6 | - [User Authentication Using LDAP Backend](ldap-user-auth.md)
7 | - [Call Forwarding Using AVP](call_forwarding.md)
8 |
--------------------------------------------------------------------------------
/docs/tutorials/security/security-threats.md:
--------------------------------------------------------------------------------
1 | # Overview of Security issues for SIP routers
2 |
3 | Author of initial tutorial:
4 | Davy Van De Moere
5 |
6 |
7 | An attempt to give a full overview of security risks a SIP Router is
8 | confronted with.
9 |
10 | ## Security Risks
11 |
12 | Quoting shamelessly from [RFC3261 Chapter 26](http://www.ietf.org/rfc/rfc3261.txt):
13 |
14 | `SIP is not an easy protocol to secure. Its use of intermediaries, its multi-faceted trust relationships, its expected usage between elements with no trust at all, and its user-to-user operation make security far from trivial.`
15 |
16 | Risks:
17 |
18 | 1\. Registration Hijacking (rfc3261)
19 |
20 | 2\. Impersonating a Server (rfc3261)
21 |
22 | 3\. Tampering with Message Bodies (rfc3261)
23 |
24 | 4\. Tearing Down Sessions (rfc3261)
25 |
26 | 5\. Denial of Service and Amplification (rfc3261)
27 |
28 | 6\. Scanning attacks
29 |
30 | 7\. Session re-use
31 |
32 | 8\. ...
33 |
--------------------------------------------------------------------------------
/docs/tutorials/tls/howto-openssl-1-0.md:
--------------------------------------------------------------------------------
1 | # Howto switch to OpenSSL 1.0 for TLS Connections
2 |
3 | ## Debian and Ubuntu
4 |
5 | First of all you need to make and install OpenSSL 1.0.2r from source.
6 |
7 | sudo apt install build-essential checkinstall zlib1g-dev -y
8 |
9 | cd /usr/src
10 |
11 | wget https://www.openssl.org/source/openssl-1.0.2r.tar.gz
12 |
13 | tar -xvzf openssl-1.0.2r.tar.gz
14 |
15 | cd openssl-1.0.2r
16 |
17 | ./config -d --prefix=/usr/local/ssl --openssldir=/usr/local/ssl shared zlib
18 |
19 | make
20 | make test
21 |
22 | make install
23 |
24 | nano /etc/ld.so.conf.d/openssl-1.0.2r.conf
25 |
26 | Add this line and save:
27 |
28 | /usr/local/ssl/lib
29 |
30 | sudo ldconfig -v
31 |
32 | mv /usr/bin/c_rehash /usr/bin/c_rehash.BEKUP
33 | mv /usr/bin/openssl /usr/bin/openssl.BEKUP
34 |
35 | export PATH=$PATH:/usr/local/ssl/bin
36 |
37 | Link binaries to path:
38 |
39 | sudo ln -s /usr/local/ssl/bin/c_rehash /usr/bin/c_rehash
40 | sudo ln -s /usr/local/ssl/bin/openssl /usr/bin/openssl
41 |
42 | Restart.
43 |
44 | sudo shutdown -r now
45 |
46 | Check OpenSSL path, should return '/usr/bin/openssl'.
47 |
48 | which openssl
49 |
50 | Check OpenSSL version, should return 'OpenSSL 1.0.2r 26 Feb 2019'.
51 |
52 | openssl version
53 |
54 | Modify '/usr/src/kamailio/src/modules/tls/makefile'.
55 |
56 | Change this:
57 |
58 | ifneq ($(SSL_BUILDER),)
59 | DEFS += $(shell $(SSL_BUILDER) --cflags)
60 | LIBS += $(shell $(SSL_BUILDER) --libs)
61 | else
62 | DEFS += -I$(LOCALBASE)/ssl/include
63 | LIBS += -L$(LOCALBASE)/lib -L$(LOCALBASE)/ssl/lib \
64 | -L$(LOCALBASE)/lib64 -L$(LOCALBASE)/ssl/lib64 \
65 | -lssl -lcrypto
66 | # NOTE: depending on the way in which libssl was compiled you might
67 | # have to add -lz -lkrb5 (zlib and kerberos5).
68 | # E.g.: make TLS_HOOKS=1 TLS_EXTRA_LIBS="-lz -lkrb5"
69 | endif
70 |
71 | To this:
72 |
73 | DEFS+= -I/usr/local/ssl/include
74 | LIBS+= -L/usr/local/ssl/lib \
75 | -lssl -lcrypto
76 |
77 | Make clean, make and make install:
78 |
79 | cd /usr/src/kamailio/src/modules/tls
80 | make clean
81 | make
82 | make install
83 |
--------------------------------------------------------------------------------
/fmt/mdbook/SUMMARY.md:
--------------------------------------------------------------------------------
1 | # Summary
2 |
3 | - [Index](./index.md)
4 | - [Download](./index.md)
5 | - [CookBooks](./index.md)
6 | - [Devel](./cookbooks/devel/core.md)
7 | - [5.5.x](./cookbooks/5.5.x/core.md)
8 | - [5.4.x](./cookbooks/5.4.x/core.md)
9 | - [5.3.x](./cookbooks/5.3.x/core.md)
10 | - [5.2.x](./cookbooks/5.2.x/core.md)
11 | - [5.1.x](./cookbooks/5.1.x/core.md)
12 | - [5.0.x](./cookbooks/5.0.x/core.md)
13 | - [4.4.x](./cookbooks/4.4.x/core.md)
14 | - [4.3.x](./cookbooks/4.3.x/core.md)
15 |
--------------------------------------------------------------------------------
/fmt/mdbook/book.toml:
--------------------------------------------------------------------------------
1 | [book]
2 | authors = ["Kamailio Developers and Contributors"]
3 | language = "en"
4 | multilingual = false
5 | src = "../../docs"
6 | title = "Kamailio Wiki Documentation"
7 |
--------------------------------------------------------------------------------
/fmt/mdbook/src/SUMMARY.md:
--------------------------------------------------------------------------------
1 | # Summary
2 |
3 | - [Chapter 1](./chapter_1.md)
4 |
--------------------------------------------------------------------------------
/fmt/mdbook/src/chapter_1.md:
--------------------------------------------------------------------------------
1 | # Chapter 1
2 |
--------------------------------------------------------------------------------
/fmt/mkdocs/mkdocs.yml:
--------------------------------------------------------------------------------
1 | site_name: Kamailio Wiki Documentation
2 | docs_dir: '../../docs'
3 | site_dir: '../../html/mkdocs'
4 | theme:
5 | name: mkdocs
6 | navigation_depth: 3
7 | extra_css:
8 | - '_xcfg/mkdocs/css/custom.css'
9 | markdown_extensions:
10 | - attr_list
11 | - pymdownx.emoji:
12 | emoji_index: !!python/name:pymdownx.emoji.gemoji
13 | emoji_generator: !!python/name:pymdownx.emoji.to_svg
14 | - pymdownx.highlight:
15 | anchor_linenums: true
16 | - pymdownx.inlinehilite
17 | - pymdownx.snippets
18 | - pymdownx.superfences
19 | - toc:
20 | toc_depth: 3
21 | nav:
22 | - 'Wiki Home': index.md
23 | - 'Kamailio Site': 'https://www.kamailio.org/'
24 | - 'Docs Index': 'http://www.kamailio.org/docs/'
25 | - 'Modules Docs': 'http://www.kamailio.org/docs/modules/'
26 | - 'Old Wiki': 'http://www.kamailio.org/dokuwiki/'
--------------------------------------------------------------------------------
/fmt/pandoc/links.lua:
--------------------------------------------------------------------------------
1 | # links-to-html.lua
2 | function Link(el)
3 | el.target = string.gsub(el.target, "%.md", ".html")
4 | return el
5 | end
6 |
--------------------------------------------------------------------------------
/fmt/pandoc/template.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 | $for(author-meta)$
8 |
9 | $endfor$
10 | $if(date-meta)$
11 |
12 | $endif$
13 | $if(keywords)$
14 |
15 | $endif$
16 | $if(description-meta)$
17 |
18 | $endif$
19 | $if(title-prefix)$$title-prefix$ – $endif$$pagetitle$ - Kamailio Wiki
20 | $for(css)$
21 |
22 | $endfor$
23 | $if(math)$
24 | $math$
25 | $endif$
26 | $for(header-includes)$
27 | $header-includes$
28 | $endfor$
29 |
50 |
51 |
52 | $for(include-before)$
53 | $include-before$
54 | $endfor$
55 |
56 |
57 |