This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const express = require('express'); | |
const request = require('supertest'); | |
const chai = require('chai'); | |
const should = chai.should(); | |
const app = express(); | |
app.post('/plain', function(req, res){ | |
res.set('Transfer-Encoding', 'chunked'); // <- this is the problem | |
res.status(200).send('hello'); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.ByteArrayOutputStream; | |
import java.io.IOException; | |
import org.apache.http.HttpStatus; | |
import org.apache.http.HttpHost; | |
import org.apache.http.HttpResponse; | |
import org.apache.http.client.ClientProtocolException; | |
import org.apache.http.client.methods.HttpGet; | |
import org.apache.http.impl.client.CloseableHttpClient; | |
import org.apache.http.impl.client.HttpClients; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Michaels-MacBook-Pro-2:~ Mike$ openssl s_client -connect open.t.qq.com:443 -showcerts | |
CONNECTED(00000003) | |
depth=0 C = CN, ST = Guangdong, L = Shenzhen, O = Tencent, CN = nginx | |
verify error:num=18:self signed certificate | |
verify return:1 | |
depth=0 C = CN, ST = Guangdong, L = Shenzhen, O = Tencent, CN = nginx | |
verify error:num=10:certificate has expired | |
notAfter=Oct 10 01:06:33 2014 GMT | |
verify return:1 | |
depth=0 C = CN, ST = Guangdong, L = Shenzhen, O = Tencent, CN = nginx |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am mikelax on github. | |
* I am mikelax (https://keybase.io/mikelax) on keybase. | |
* I have a public key whose fingerprint is 666F 3F56 CC11 6D02 8C0E D13C 8336 34EC CED9 8E42 | |
To claim this, I am signing this object: |