### Fix
- Fix integration test
- https://jira.onap.org/browse/INT-1844
+
+## [1.0.5]
+
+### Changed
+ - httpserver to be consistent with DFC csit/integration test cases
+ - https://jira.onap.org/browse/DCAEGEN2-2536
<parent>
<groupId>org.onap.integration.simulators.pnf-simulator</groupId>
<artifactId>integration-pnf-simulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
</parent>
<artifactId>onboarding-package</artifactId>
<build>
ENV APACHE_LOCK_DIR /var/lock/apache2
ENV APACHE_PID_FILE /var/run/apache2.pid
-ADD resources/.htpasswd /usr/local/apache2/passwd/.htpasswd
-ADD resources/.htaccess /usr/local/apache2/htdocs/.htaccess
-ADD resources/upload.php /usr/local/apache2/conf/upload.php
-ADD resources/apache-config.conf /etc/apache2/sites-enabled/000-default.conf
-ADD resources/apache2.conf /etc/apache2/apache2.conf
-ADD resources/cert/ /etc/apache2/certs/
+COPY --chown=root:root resources/local/.htpasswd /usr/local/apache2/passwd/.htpasswd
+COPY --chown=root:root resources/local/upload.php /usr/local/apache2/conf/upload.php
+COPY --chown=root:root resources/sites-enabled/000-default.conf /etc/apache2/sites-enabled/000-default.conf
+COPY --chown=root:root resources/ports.conf /etc/apache2/ports.conf
+COPY --chown=root:root resources/apache2.conf /etc/apache2/apache2.conf
+COPY --chown=root:root resources/cert/ /etc/apache2/certs/
+
+COPY --chown=root:root resources/lib/libjwt.so.1.7.0 /usr/lib/x86_64-linux-gnu/libjwt.so.1
+COPY --chown=root:root resources/modules/mod_authnz_jwt.so /usr/local/apache2/modules/mod_authnz_jwt.so
+COPY --chown=root:root resources/mods-enabled/auth_jwt.load /etc/apache2/mods-enabled/auth_jwt.load
+
+RUN chmod 644 /usr/local/apache2/passwd/.htpasswd
+RUN chmod 644 /usr/local/apache2/conf/httpd.conf
+RUN chmod 644 /usr/lib/x86_64-linux-gnu/libjwt.so.1
+RUN chmod 644 /usr/local/apache2/modules/mod_authnz_jwt.so
+RUN touch /usr/local/apache2/htdocs/index.html
+CMD ["/usr/sbin/apache2ctl", "-D", "FOREGROUND"]
```
make stop-http-server
```
+
+### mod_authnz_jwt.so
+
+External library `mod_authnz_jwt.so` was added to the Apache server. This library wasn't changed in any way.
+This library is supplied under the Apache License, Version 2.0 (the "License"). More info is available at
+https://github.com/AnthonyDeroche/mod_authnz_jwt .
http-server:
image: onap/org.onap.integration.simulators.httpserver
ports:
- - "7080:80"
- - "7443:443"
+ - "32080:80"
+ - "8080:8080"
+ - "32443:443"
+ - "32000:32000"
+ - "32100:32100"
volumes:
- ~/httpservervolumes/:/usr/local/apache2/htdocs
- - ./resources/.htaccess:/usr/local/apache2/htdocs/.htaccess
- ./logs:/var/log/apache2
command: bash -c "
echo 'Http Server start';
while [[ $$(ls -1 /etc/apache2/certs/ | wc -l) != '3' ]]; do echo 'Waiting for certs...'; sleep 3; done;
chmod 777 /usr/local/apache2/htdocs;
cp /usr/local/apache2/conf/upload.php /usr/local/apache2/htdocs/upload.php;
+ touch /usr/local/apache2/htdocs/index.html;
/usr/sbin/apache2ctl -D FOREGROUND;
"
restart: on-failure
<parent>
<groupId>org.onap.integration.simulators.pnf-simulator</groupId>
<artifactId>integration-pnf-simulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
</parent>
<artifactId>httpserver</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+++ /dev/null
- AuthType Basic
- AuthName "Secure file"
- AuthBasicProvider file
- AuthUserFile "/usr/local/apache2/passwd/.htpasswd"
- Require valid-user
+++ /dev/null
-<VirtualHost *:80>
- ServerAdmin httpserver-onap.org
- ServerName httpserver-onap.org
-
- DocumentRoot /usr/local/apache2/htdocs
- <Directory /usr/local/apache2/htdocs>
- Options Indexes FollowSymLinks MultiViews
- AllowOverride AuthConfig
- Require all granted
- </Directory>
-
- ErrorLog ${APACHE_LOG_DIR}/error.log
- CustomLog ${APACHE_LOG_DIR}/access.log combined
-</VirtualHost>
-
-<IfModule mod_ssl.c>
-<VirtualHost *:443>
- ServerAdmin httpserver-onap.org
- ServerName httpserver-onap.org
-
- DocumentRoot /usr/local/apache2/htdocs
- <Directory /usr/local/apache2/htdocs>
- SSLVerifyClient optional
- SSLVerifyDepth 2
- SSLOptions +FakeBasicAuth +StrictRequire
- <RequireAll>
- Require ssl-verify-client
- </RequireAll>
- Options Indexes FollowSymLinks MultiViews
- AuthType Basic
- AuthName "Secure file"
- AuthBasicProvider file
- AuthUserFile "/usr/local/apache2/passwd/.htpasswd"
- Require valid-user
- </Directory>
-
- SSLCACertificateFile /etc/apache2/certs/truststore.pem
- SSLCertificateFile /etc/apache2/certs/keystore.pem
- SSLCertificateKeyFile /etc/apache2/certs/key.pem
- SSLEngine on
- SSLProtocol -all +TLSv1.2
- SSLCipherSuite ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384
- SSLHonorCipherOrder off
- SSLSessionTickets off
-
- ErrorLog ${APACHE_LOG_DIR}/error.log
- CustomLog ${APACHE_LOG_DIR}/access.log combined
-</VirtualHost>
-</IfModule>
# for additional configuration directives. See also the AllowOverride
# directive.
#
-AccessFileName .htaccess
+#AccessFileName .htaccess
#
# The following lines prevent .htaccess and .htpasswd files from being
--- /dev/null
+LoadModule auth_jwt_module /usr/local/apache2/modules/mod_authnz_jwt.so
--- /dev/null
+Listen 80 http
+Listen 32000 http
+
+<IfModule ssl_module>
+ Listen 443 https
+ Listen 8080 https
+ Listen 32100 https
+</IfModule>
+
+<IfModule mod_gnutls.c>
+ Listen 443 https
+ Listen 8080 https
+ Listen 32100 https
+</IfModule>
--- /dev/null
+<VirtualHost *:80>
+ ServerAdmin httpserver-onap.org
+ ServerName httpserver-onap.org
+
+ DocumentRoot /usr/local/apache2/htdocs
+ <Directory /usr/local/apache2/htdocs>
+ Options Indexes FollowSymLinks MultiViews
+ AllowOverride None
+ AuthType Basic
+ AuthName "Secure file"
+ AuthBasicProvider file
+ AuthUserFile "/usr/local/apache2/passwd/.htpasswd"
+ Require valid-user
+ </Directory>
+
+ ErrorLog ${APACHE_LOG_DIR}/error.log
+ CustomLog ${APACHE_LOG_DIR}/access.log combined
+</VirtualHost>
+<VirtualHost *:32000>
+
+ ServerAdmin httpserver-onap.org
+ DocumentRoot "/usr/local/apache2/htdocs"
+
+ AuthJWTSignatureAlgorithm HS256
+ AuthJWTSignatureSharedSecret Q0hBTkdFTUU=
+ AuthJWTIss onap
+ <Directory "/usr/local/apache2/htdocs">
+ AllowOverride None
+ Options Indexes FollowSymLinks MultiViews
+ AuthType jwt
+ AuthName "Restricted Content"
+ Require valid-user
+ RewriteEngine On
+ RewriteCond %{HTTP:Authorization} ^(.*)
+ RewriteRule .* - [e=HTTP_AUTHORIZATION:%1]
+ </Directory>
+
+ ErrorLog ${APACHE_LOG_DIR}/error.log
+ CustomLog ${APACHE_LOG_DIR}/access.log combined
+</VirtualHost>
+
+<IfModule mod_ssl.c>
+<VirtualHost *:443>
+ ServerAdmin httpserver-onap.org
+ ServerName httpserver-onap.org
+
+ DocumentRoot /usr/local/apache2/htdocs
+ <Directory /usr/local/apache2/htdocs>
+ SSLVerifyClient optional
+ SSLVerifyDepth 2
+ SSLOptions +FakeBasicAuth +StrictRequire
+ <RequireAll>
+ Require ssl-verify-client
+ </RequireAll>
+ Options Indexes FollowSymLinks MultiViews
+ AuthType Basic
+ AuthName "Secure file"
+ AuthBasicProvider file
+ AuthUserFile "/usr/local/apache2/passwd/.htpasswd"
+ Require valid-user
+ </Directory>
+
+ SSLCACertificateFile /etc/apache2/certs/truststore.pem
+ SSLCertificateFile /etc/apache2/certs/keystore.pem
+ SSLCertificateKeyFile /etc/apache2/certs/key.pem
+ SSLEngine on
+ SSLProtocol -all +TLSv1.2
+ SSLCipherSuite ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384
+ SSLHonorCipherOrder off
+ SSLSessionTickets off
+
+ ErrorLog ${APACHE_LOG_DIR}/error.log
+ CustomLog ${APACHE_LOG_DIR}/access.log combined
+</VirtualHost>
+
+<VirtualHost *:8080>
+ ServerAdmin httpserver-onap.org
+ ServerName httpserver-onap.org
+
+ DocumentRoot /usr/local/apache2/htdocs
+ <Directory "/usr/local/apache2/htdocs">
+ Require all granted
+ </Directory>
+
+ ErrorLog ${APACHE_LOG_DIR}/error.log
+ CustomLog ${APACHE_LOG_DIR}/access.log combined
+
+ SSLEngine on
+ SSLProtocol -all +TLSv1.2
+ SSLCipherSuite ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384
+ SSLHonorCipherOrder off
+ SSLSessionTickets off
+
+ SSLCACertificateFile /etc/apache2/certs/truststore.pem
+ SSLCertificateFile /etc/apache2/certs/keystore.pem
+ SSLCertificateKeyFile /etc/apache2/certs/key.pem
+</VirtualHost>
+
+<VirtualHost *:32100>
+
+ ServerAdmin httpserver-onap.org
+ ServerName httpserver-onap.org
+
+ DocumentRoot /usr/local/apache2/htdocs
+ AuthJWTSignatureAlgorithm HS256
+ AuthJWTSignatureSharedSecret Q0hBTkdFTUU=
+ AuthJWTIss onap
+ <Directory "/usr/local/apache2/htdocs">
+ AllowOverride None
+ Options Indexes FollowSymLinks MultiViews
+ AuthType jwt
+ AuthName "Restricted Content"
+ Require valid-user
+ RewriteEngine On
+ RewriteCond %{HTTP:Authorization} ^(.*)
+ RewriteRule .* - [e=HTTP_AUTHORIZATION:%1]
+ </Directory>
+
+ ErrorLog ${APACHE_LOG_DIR}/error.log
+ CustomLog ${APACHE_LOG_DIR}/access.log combined
+
+ SSLEngine on
+ SSLProtocol -all +TLSv1.2
+ SSLCipherSuite ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384
+ SSLHonorCipherOrder off
+ SSLSessionTickets off
+
+ SSLCACertificateFile /etc/apache2/certs/truststore.pem
+ SSLCertificateFile /etc/apache2/certs/keystore.pem
+ SSLCertificateKeyFile /etc/apache2/certs/key.pem
+</VirtualHost>
+</IfModule>
<parent>
<groupId>org.onap.integration.simulators.pnf-simulator</groupId>
<artifactId>integration-pnf-simulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
</parent>
<artifactId>netconfsimulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<parent>
<groupId>org.onap.integration.simulators.pnf-simulator</groupId>
<artifactId>integration-pnf-simulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<artifactId>pnf-simulator-integration</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
<name>pnf-simulator-integration</name>
<repositories>
<parent>
<groupId>org.onap.integration.simulators.pnf-simulator</groupId>
<artifactId>integration-pnf-simulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
</parent>
<artifactId>pnfsimulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
<name>pnfsimulator</name>
{
"name": "C_28532_measData_pm_98.xml",
"hashMap": {
- "location": "http://httpserver:httpserver@localhost:7080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
+ "location": "http://demo:demo123456!@localhost:32080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
"compression": "gzip",
"fileFormatType": "org.3GPP.32.435#measCollec",
"fileFormatVersion": "V10"
{
"name": "C_28532_measData_pm_99.xml",
"hashMap": {
- "location": "http://httpserver:httpserver@localhost:7080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
+ "location": "http://demo:demo123456!@localhost:32080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
"compression": "gzip",
"fileFormatType": "org.3GPP.32.435#measCollec",
"fileFormatVersion": "V10"
{
"name": "C_28532_measData_pm_100.xml",
"hashMap": {
- "location": "http://httpserver:httpserver@localhost:7080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
+ "location": "http://demo:demo123456!@localhost:32080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
"compression": "gzip",
"fileFormatType": "org.3GPP.32.435#measCollec",
"fileFormatVersion": "V10"
<groupId>org.onap.integration.simulators.pnf-simulator</groupId>
<artifactId>integration-pnf-simulator</artifactId>
- <version>1.0.4-SNAPSHOT</version>
+ <version>1.0.5-SNAPSHOT</version>
<modules>
<module>pnfsimulator</module>
<module>httpserver</module>
upload-file-http-server:
@echo "##### Upload file to Http server #####"
- curl -F "uploaded_file=@./resources/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz" -u demo:demo123456! http://localhost:7080/upload.php
+ curl -F "uploaded_file=@./resources/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz" -u demo:demo123456! http://localhost:32080/upload.php
@echo "\n##### DONE #####"
generate-event:
{
"name": "C_28532_measData_pm_98.xml",
"hashMap": {
- "location": "http://httpserver:httpserver@localhost:7080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
+ "location": "http://demo:demo123456!@localhost:32080/E_VES_bulkPM_IF_3GPP_3_example_1.xml.gz",
"compression": "gzip",
"fileFormatType": "org.3GPP.32.435#measCollec",
"fileFormatVersion": "V10"
services:
oom-cert-client-ves:
- image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-client:2.1.0
+ image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-client:2.1.1
container_name: oomcert-client-for-ves
env_file: ./resources/certservice-client/client-configuration-for-ves.env
networks:
- ./resources/certs/certServiceClient-keystore.jks:/etc/onap/oom/certservice/certs/certServiceClient-keystore.jks
oom-cert-client-pnfsim:
- image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-client:2.1.0
+ image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-client:2.1.1
container_name: oomcert-client
env_file: ./resources/certservice-client/client-configuration-for-pnfsim.env
networks:
- ./resources/certs/certServiceClient-keystore.jks:/etc/onap/oom/certservice/certs/certServiceClient-keystore.jks
oom-cert-client-httpserver:
- image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-client:2.1.0
+ image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-client:2.1.1
container_name: oomcert-client-for-httpserver
env_file: ./resources/certservice-client/client-configuration-for-httpserver.env
networks:
- onap
oom-cert-service:
- image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-api:2.1.0
+ image: nexus3.onap.org:10001/onap/org.onap.oom.platform.cert-service.oom-certservice-api:2.1.1
volumes:
- ./resources/certservice/cmpServers.json:/etc/onap/oom/certservice/cmpServers.json
- ./resources/certs/truststore.jks:/etc/onap/oom/certservice/certs/truststore.jks
http-server:
image: nexus3.onap.org:10003/onap/org.onap.integration.simulators.httpserver
ports:
- - "7080:80"
- - "7443:443"
+ - "8080:8080"
+ - "32000:32000"
+ - "32080:80"
+ - "32100:32100"
+ - "32443:443"
networks:
- pnfsimulator
- public
volumes:
- ~/httpservervolumes/:/usr/local/apache2/htdocs
- - ../../../httpserver/resources/.htaccess:/usr/local/apache2/htdocs/.htaccess
- ../../../httpserver/logs:/var/log/apache2
- ./resources/certservice-client/client-volume-for-httpserver/:/etc/apache2/certs/
command: bash -c "
while [[ $$(ls -1 /etc/apache2/certs/ | wc -l) != '3' ]]; do echo 'Waiting for certs...'; sleep 3; done;
chmod 777 /usr/local/apache2/htdocs;
cp /usr/local/apache2/conf/upload.php /usr/local/apache2/htdocs/upload.php;
+ touch /usr/local/apache2/htdocs/index.html;
/usr/sbin/apache2ctl -D FOREGROUND;
"
restart: on-failure
--- /dev/null
+*.jks
+*.p12
+*.crt
--- /dev/null
+client-volume-for-httpserver
+client-volume-for-pnfsim
+client-volume-for-ves