Apache 2.4.17 en http2

Pagina: 1
Acties:

  • Keiichi
  • Registratie: Juni 2005
  • Laatst online: 14:52
Ik heb een FreeBSD 10.1 bak met zelf gecompiled ports. Ik heb hierbij apache 2.4.17 met http2 ondersteuning. Ik krijg het niet werkend. De server draait wel, waar er komt geen http2 'connectie' (getest met spdy/http2 indicator in chrome)

Ik had ergens op een tutorial gezien dat OpenSSL 1.0.2 nodig is, maar ik krijg dit nergens bevestigd. In FreeBSD maak ik gebruik van openssl uit de base, omdat de ports openssl problemen oplevert met verschillende ports.

Solar @ Dongen: http://solar.searchy.net/ - Penpal International: http://ppi.searchy.net/


  • duiveltje666
  • Registratie: Mei 2005
  • Laatst online: 13-06-2022
en wat krijg je met curl -v --http2 http://jedomein?
Spdy =/= http2 namelijk

  • Ruubster
  • Registratie: Augustus 2008
  • Niet online
https://icing.github.io/mod_h2/howto.html onder het kopje TLS Support. Je hebt HTTPS nodig, heb je dat aanstaan? Daar heb je OpenSSL oid voor nodig.

  • johnkeates
  • Registratie: Februari 2008
  • Laatst online: 04-07 16:30
Je hebt inderdaad met TLS en HTTP/2 NPN of ALPN ondersteuning in OpenSSL nodig.

  • Blokker_1999
  • Registratie: Februari 2003
  • Laatst online: 13:50

Blokker_1999

Full steam ahead

http/2 werkt enkel en alleen met SSL beveiligde pagina's. Hoewel de vereiste van SSL NIET is opgenomen in de standaard is er geen enkele grote browser die een http/2 verbinding opzet op een non-ssl connectie.

Zorg er dus zeker voor dat je site bereikbaar is (met een certificaat) op https://url en als dan alles in orde is zal je een http/2 verbinding hebben.
duiveltje666 schreef op donderdag 10 december 2015 @ 15:28:
en wat krijg je met curl -v --http2 http://jedomein?
Spdy =/= http2 namelijk
Daat http/2 een doorontwikkeling is van spdy hebben de meeste indicatoren van spdy de mogelijkheid gekregen om ook http/2 weer te geven. En om helemaal goed te zijn moet je die curl dus doen op https://

[ Voor 35% gewijzigd door Blokker_1999 op 10-12-2015 19:32 ]

No keyboard detected. Press F1 to continue.


  • Keiichi
  • Registratie: Juni 2005
  • Laatst online: 14:52
duiveltje666 schreef op donderdag 10 december 2015 @ 15:28:
en wat krijg je met curl -v --http2 http://jedomein?
Spdy =/= http2 namelijk
Dan krijg ik:

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
* Rebuilt URL to: https://jedomein
*   Trying 2a00:1234:1234:4::2...
* Connected to jedomein (2a00:1234:1234:4::2) port 443 (#0)
* Cipher selection: ALL:!EXPORT:!EXPORT40:!EXPORT56:!aNULL:!LOW:!RC4:@STRENGTH
* successfully set certificate verify locations:
*   CAfile: /etc/ssl/certs/ca-certificates.crt
  CApath: none
* TLSv1.2 (OUT), TLS handshake, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS change cipher, Client hello (1):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS change cipher, Client hello (1):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES256-GCM-SHA384
* Server certificate:
*        subject: OU=Domain Control Validated; OU=PositiveSSL Wildcard; CN=jedomein
*        start date: Aug  6 00:00:00 2015 GMT
*        expire date: Aug  5 23:59:59 2016 GMT
*        subjectAltName: jedomein matched
*        issuer: C=GB; ST=Greater Manchester; L=Salford; O=COMODO CA Limited; CN=COMODO RSA Domain Validation Secure Server CA
*        SSL certificate verify ok.
> GET / HTTP/1.1
> Host: jedomein
> User-Agent: curl/7.46.0
> Accept: */*
> 
< HTTP/1.1 200 OK
< Date: Thu, 10 Dec 2015 19:17:26 GMT
< Server: Apache/2.4.17 (FreeBSD) mod_fastcgi/mod_fastcgi-SNAP-0910052141 OpenSSL/1.0.1p-freebsd
< X-Powered-By: PHP/5.6.16
< Set-Cookie: oc8sdfsdfsdfdfa=1962da3d272sdfsdfsdfd0; path=/; HttpOnly
< Expires: Thu, 19 Nov 1981 08:52:00 GMT
< Cache-Control: no-store, no-cache, must-revalidate, post-check=0, pre-check=0
< Pragma: no-cache
< Set-Cookie: oc_sessionPassphrase=6xmGQ7unV3epmtF1IZCIJzYj1OWwT1A8tWlTrIgZs6MonQcldezecookieisnunietmeertegebruikenTdZRIP6%2BNRO0RGFBIRtn3thugfu@#$cvb#$v5Bsux1; path=/; secure; httponly
< Content-Security-Policy: default-src 'self'; script-src 'self' 'unsafe-eval'; style-src 'self' 'unsafe-inline'; frame-src *; img-src * data: blob:; font-src 'self' data:; media-src *; connect-src *
< X-XSS-Protection: 1; mode=block
< X-Content-Type-Options: nosniff
< X-Frame-Options: Sameorigin
< X-Robots-Tag: none
< Transfer-Encoding: chunked
< Content-Type: text/html; charset=UTF-8


Met een andere test 'openssl s_client -connect jedomein:443 -nextprotoneg '' ' krijg ik niets te zien zoals bij ( Niets in de zin dat ik nu over ssl gewoon kan gaan babbellen zoals in 'telnet' )

code:
1
2
3
4
oot@venus:~/download/curl-7.46.0# openssl s_client -connect google.com:443 -nextprotoneg ''
CONNECTED(00000003)
Protocols advertised by server: h2, spdy/3.1, http/1.1
3073959612:error:140920E3:SSL routines:SSL3_GET_SERVER_HELLO:parse tlsext:s3_clnt.c:1061:

Solar @ Dongen: http://solar.searchy.net/ - Penpal International: http://ppi.searchy.net/


  • CAPSLOCK2000
  • Registratie: Februari 2003
  • Laatst online: 12:22

CAPSLOCK2000

zie teletekst pagina 888

In die curl zie ik niks dat op http2 lijkt. Dat openssl ook niet wil suggereert dat het toch bij Apache zit.
Wat staat er in de logs van Apache?
Heb je iets geconfigureerd?
Is de module wel geladen?
Heb je enige aanwijzing dat jouw Apache 2.4 inderaad http2 actief heeft?

This post is warranted for the full amount you paid me for it.


  • GieltjE
  • Registratie: December 2003
  • Laatst online: 27-09 21:50

GieltjE

Niks te zien...

ProtocolsHonorOrder On
Protocols h2 http/1.1

Heb je dat wel in je config staan? Je hebt inderdaad https nodig, je kan met h2c http2 over http doen maar dat werkt absoluut niet lekker.

[ Voor 6% gewijzigd door GieltjE op 10-12-2015 23:09 ]

Hell / 0


Acties:
  • 0 Henk 'm!

  • Keiichi
  • Registratie: Juni 2005
  • Laatst online: 14:52
Ik heb dit in mijn config staan:
code:
1
2
3
4
5
6
ProtocolsHonorOrder On
Protocols h2 h2c http/1.1

<IfModule http2_module>
    LogLevel http2:debug
</IfModule>


M'n http errorlog is:

code:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
[Fri Dec 11 07:49:04.656135 2015] [suexec:notice] [pid 26087] AH01232: suEXEC mechanism enabled (wrapper: /usr/local/sbin/suexec)
[Fri Dec 11 07:49:04.658109 2015] [http2:debug] [pid 26087] mod_http2.c(74): initializing post config dry run
[Fri Dec 11 07:49:04.698374 2015] [ssl:warn] [pid 26089] AH01873: Init: Session Cache is not configured [hint: SSLSessionCache]
[Fri Dec 11 07:49:04.700690 2015] [http2:info] [pid 26089] mod_http2 (v1.0.0, nghttp2 1.5.0), initializing...
[Fri Dec 11 07:49:04.700711 2015] [http2:debug] [pid 26089] h2_h2.c(72): h2_h2, child_init
[Fri Dec 11 07:49:04.700718 2015] [http2:debug] [pid 26089] h2_switch.c(54): h2_switch init
[Fri Dec 11 07:49:04.704286 2015] [mpm_prefork:notice] [pid 26089] AH00163: Apache/2.4.17 (FreeBSD) mod_fastcgi/mod_fastcgi-SNAP-0910052141 OpenSSL/1.0.1p-freebsd configured -- resuming normal operations
[Fri Dec 11 07:49:04.704353 2015] [core:notice] [pid 26089] AH00094: Command line: '/usr/local/sbin/httpd -D NOHTTPACCEPT'
[Fri Dec 11 07:49:04.732930 2015] [:notice] [pid 26091] FastCGI: process manager initialized (pid 26091)
[Fri Dec 11 07:49:04.733360 2015] [http2:debug] [pid 26094] h2_conn.c(121): h2_workers: min=1 max=1, mthrpchild=1, thr_limit=1
[Fri Dec 11 07:49:04.733396 2015] [http2:debug] [pid 26094] h2_workers.c(226): h2_workers: starting
[Fri Dec 11 07:49:04.733766 2015] [http2:debug] [pid 26093] h2_conn.c(121): h2_workers: min=1 max=1, mthrpchild=1, thr_limit=1
[Fri Dec 11 07:49:04.733816 2015] [http2:debug] [pid 26093] h2_workers.c(226): h2_workers: starting
[Fri Dec 11 07:49:04.735095 2015] [http2:debug] [pid 26092] h2_conn.c(121): h2_workers: min=1 max=1, mthrpchild=1, thr_limit=1
[Fri Dec 11 07:49:04.735129 2015] [http2:debug] [pid 26092] h2_workers.c(226): h2_workers: starting
[Fri Dec 11 07:49:04.750871 2015] [http2:debug] [pid 26095] h2_conn.c(121): h2_workers: min=1 max=1, mthrpchild=1, thr_limit=1
[Fri Dec 11 07:49:04.750904 2015] [http2:debug] [pid 26095] h2_workers.c(226): h2_workers: starting
[Fri Dec 11 07:49:04.755952 2015] [http2:debug] [pid 26096] h2_conn.c(121): h2_workers: min=1 max=1, mthrpchild=1, thr_limit=1
[Fri Dec 11 07:49:04.755985 2015] [http2:debug] [pid 26096] h2_workers.c(226): h2_workers: starting

(zojuist nog even opnieuw gestart om makkelijk de eerste stuk van de log te pakken)

Behalve deze logs over http2, zie ik niets meer verschijnen.

Voor mij lijkt het nu dat NPN niet werkt Dit zou sinds openssl 1.0.1 erin zitten.

Solar @ Dongen: http://solar.searchy.net/ - Penpal International: http://ppi.searchy.net/


Acties:
  • 0 Henk 'm!

  • Keiichi
  • Registratie: Juni 2005
  • Laatst online: 14:52
Ik heb alles opnieuw gecompiled met openssl 1.0.2e . http2 werkt nu wel.ALPN wordt wordt hierbij gebruikt (zit ook vanaf 1.0.2 erin). NPN werkt niet.

Ik had begrepen dat ALPN favorable boven NPN is en dat chrome NPN zal laten varen.

Heeft het nog zin/nut om NPN werkend proberen te krijgen?

Solar @ Dongen: http://solar.searchy.net/ - Penpal International: http://ppi.searchy.net/


Acties:
  • 0 Henk 'm!

  • Thc_Nbl
  • Registratie: Juli 2001
  • Laatst online: 21-05 22:24
NPN is alweer vervangen voor ALPN staat ergens in de bugtrackers.
Dus nee, heeft weinig zin.

ehhh.. noppes

Pagina: 1