Skip to content

Commit ef3a75f

Browse files
author
Nick Altmann
committed
RPM packaging: add auth_jwt module package, but exclude it from build because there is no libjwt in centos/fedora
1 parent f7efd44 commit ef3a75f

File tree

1 file changed

+32
-1
lines changed

1 file changed

+32
-1
lines changed

packaging/redhat_fedora/opensips.spec

Lines changed: 32 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
%global _with_python3 1
2626
%endif
2727

28-
%global EXCLUDE_MODULES %{!?_with_cachedb_cassandra:cachedb_cassandra} %{!?_with_cachedb_couchbase:cachedb_couchbase} %{!?_with_cachedb_mongodb:cachedb_mongodb} %{!?_with_cachedb_redis:cachedb_redis} %{!?_with_db_oracle:db_oracle} %{!?_with_osp:osp} %{!?_with_sngtc:sngtc} %{?_without_aaa_radius:aaa_radius} %{?_without_db_perlvdb:db_perlvdb} %{?_without_snmpstats:snmpstats}
28+
%global EXCLUDE_MODULES %{!?_with_auth_jwt:auth_jwt} %{!?_with_cachedb_cassandra:cachedb_cassandra} %{!?_with_cachedb_couchbase:cachedb_couchbase} %{!?_with_cachedb_mongodb:cachedb_mongodb} %{!?_with_cachedb_redis:cachedb_redis} %{!?_with_db_oracle:db_oracle} %{!?_with_osp:osp} %{!?_with_sngtc:sngtc} %{?_without_aaa_radius:aaa_radius} %{?_without_db_perlvdb:db_perlvdb} %{?_without_snmpstats:snmpstats}
2929

3030
Summary: Very fast and configurable SIP server
3131
Name: opensips
@@ -107,6 +107,31 @@ XMLRPC Interface.
107107
This package contains the main OpenSIPS binary along with the principal modules
108108
and support binaries including opensipsmc configuration tool.
109109

110+
%if 0%{?_with_auth_jwt:1}
111+
%package auth-jwt-module
112+
Summary: JSON Web Tokens authentication module for OpenSIPS
113+
Group: System Environment/Daemons
114+
Requires: %{name} = %{version}-%{release}
115+
116+
%description auth-jwt-module
117+
OpenSIPS is a very fast and flexible SIP (RFC3261)
118+
server. Written entirely in C, OpenSIPS can handle thousands calls
119+
per second even on low-budget hardware.
120+
.
121+
The module implements authentication over JSON Web Tokens. In
122+
some cases ( ie. WebRTC ) the user authenticates on another
123+
layer ( other than SIP ), so it makes no sense to
124+
double-authenticate it on the SIP layer. Thus, the SIP client
125+
will simply present the JWT auth token it received from the
126+
server, and pass it on to OpenSIPS which will use that for
127+
authentication purposes. It relies on two DB tables, one
128+
containing JWT profiles ( a profile name and it's SIP username
129+
associated to it ) and one containing JWT secrets. Each secret
130+
has a corresponding profile, the KEY used for signing the JWT
131+
and two timestamps describing a validation interval. Multiple
132+
JWT secrets can point to the same JWT profile.
133+
%endif
134+
110135
%package b2bua-module
111136
Summary: B2B User Agent modules for OpenSIPS
112137
Group: System Environment/Daemons
@@ -1107,6 +1132,12 @@ fi
11071132
%doc docdir/README.userblacklist
11081133
%doc docdir/README.usrloc
11091134

1135+
%if 0%{?_with_auth_jwt:1}
1136+
%files auth-jwt-module
1137+
%{_libdir}/opensips/modules/auth_jwt.so
1138+
%doc docdir/README.auth_jwt
1139+
%endif
1140+
11101141
%files b2bua-module
11111142
%{_libdir}/opensips/modules/b2b_entities.so
11121143
%{_libdir}/opensips/modules/b2b_logic.so

0 commit comments

Comments
 (0)