Neos - installation failed behind a proxy

Hi,
I am not able to install Neos behind a proxy. I’ve got the composer installed, but the installation of Neos failed always with the message: SSL23_GET_SERVER_HELLO:unknown protocol

My Environment
Linux 4.4.0-81-generic #104-Ubuntu SMP Wed Jun 14 08:17:06 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux
Ubuntu 16.04.2 LTS
Apache/2.4.18 (Ubuntu)
PHP 7.0.18-0ubuntu0.16.04.1 (cli) ( NTS )
$ printenv |grep PROXY
NO_PROXY=localhost,127.0.0.1
FTP_PROXY=ftp://192.168.1.40:3128
HTTPS_PROXY=https://192.168.1.40:3128
HTTP_PROXY_REQUEST_FULLURI=0
HTTP_PROXY=http://192.168.1.40:3128
HTTPS_PROXY_REQUEST_FULLURI=0
$ printenv |grep proxy
http_proxy_request_fulluri=0
http_proxy=http://192.168.1.40:3128
ftp_proxy=ftp://192.168.1.40:3128
https_proxy=https://192.168.1.40:3128
no_proxy=localhost,127.0.0.1
https_proxy_request_fulluri=0

What I have tried so far
I updated the proxy to the latest version and I have tried several things, but all these things without success. Now I need your help.
Here the output:

$ composer create-project -vvv --no-dev neos/neos-base-distribution . 
Reading /home/karsten/.composer/composer.json 
Loading config file /home/karsten/.composer/composer.json 
Checked CA file /etc/ssl/certs/ca-certificates.crt: valid 
Executing command (/home/karsten/.composer): git branch --no-color --no-abbrev -v 
Executing command (/home/karsten/.composer): git describe --exact-match --tags 
Executing command (/home/karsten/.composer): git log --pretty="%H" -n1 HEAD 
Running 1.3.1 (2017-01-07 18:08:51) with PHP 7.0.18-0ubuntu0.16.04.1 on Linux / 4.4.0-81-generic 
Downloading https://packagist.org/packages.json using proxy ssl://192.168.1.40:3128 
Downloading https://packagist.org/packages.json using proxy ssl://192.168.1.40:3128 
Downloading https://packagist.org/packages.json using proxy ssl://192.168.1.40:3128 
 [Composer\Downloader\TransportException]  
 The "https://packagist.org/packages.json" file could not be downloaded:  SSL operation failed with code 1. OpenSSL Error messages:   
 error:140770FC:SSL routines:SSL23_GET_SERVER_HELLO:unknown protocol                                                                 
 Failed to enable crypto                               
 failed to open stream: operation failed 

Exception trace: ...

wget works fine

$ wget https://packagist.org/packages.json
–2017-06-25 13:16:12-- https://packagist.org/packages.json
Connecting to 192.168.1.40:3128… connected.
Proxy request sent, awaiting response… 200 OK
Length: 1302 (1,3K) [application/json]
Saving to: ‘packages.json’

packages.json 100%[=========================================================================================>] 1,27K --.-KB/s in 0s

2017-06-25 13:16:12 (166 MB/s) - ‘packages.json’ saved [1302/1302]

Need your help
What is wrong? Should I configure php in a different way?
Any help is appreciated - thanks.

I have made some further investigations. I wrote a small script to check the php environment.

#!/usr/bin/php
<?php
$url = "https://packagist.org/packages.json";

function getUrlContent($url){
 $ch = curl_init();
 curl_setopt($ch, CURLOPT_URL, $url);
 curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; .NET CLR 1.1.4322)');
 curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
 curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 5);
 curl_setopt($ch, CURLOPT_TIMEOUT, 5);
 $data = curl_exec($ch);
 $httpcode = curl_getinfo($ch, CURLINFO_HTTP_CODE);
 curl_close($ch);
 return ($httpcode>=200 && $httpcode<300) ? $data : false;
}

print_r(getUrlContent($url));
?>

This script works very well and I see the output on the console. In the log file of the proxy (squid) I have found the successful message:

1498680723.028 366 192.168.1.120 TCP_TUNNEL/200 4626 CONNECT packagist.org:443 - HIER_DIRECT/87.98.253.214 -

When I use the composer the proxy server logged a client error (400 Bad Request)

1498681768.407 0 192.168.1.120 TAG_NONE/400 4462 NONE error:invalid-request - HIER_NONE/- text/html
1498681768.519 0 192.168.1.120 TAG_NONE/400 4462 NONE error:invalid-request - HIER_NONE/- text/html
1498681768.631 0 192.168.1.120 TAG_NONE/400 4462 NONE error:invalid-request - HIER_NONE/- text/html

My conclusion
php config ok. The config of the proxy seems to be correct. Composer is faulty and does not work behind a proxy.

My question to you
Is there another option to install Neos without composer?