Temporarily remove TLS helper functions

This commit is contained in:
Chris Boden 2017-09-14 08:03:44 -04:00
parent 0f827b13c9
commit 680b2ae45c
3 changed files with 3 additions and 13 deletions

View File

@ -8,12 +8,11 @@ CHANGELOG
---
* 0.4 (2017-)
* 0.4 (2017-09-14)
* BC: $conn->WebSocket->request replaced with $conn->httpRequest which is a PSR-7 object
* Binary messages now supported via Ratchet\WebSocket\MessageComponentInterface
* Added heartbeat support via ping/pong in WsServer
* TLS now supported
* BC: No longer support old (and insecure) Hixie76 and Hybi protocols
* BC: No longer support disabling UTF-8 checks
* BC: The Session component implements HttpServerInterface instead of WsServerInterface

View File

@ -60,9 +60,8 @@ class App {
* @param int $port Port to listen on. If 80, assuming production, Flash on 843 otherwise expecting Flash to be proxied through 8843
* @param string $address IP address to bind to. Default is localhost/proxy only. '0.0.0.0' for any machine.
* @param LoopInterface $loop Specific React\EventLoop to bind the application to. null will create one for you.
* @param array $sslContext An array of PHP stream context options in order to support SSL
*/
public function __construct($httpHost = 'localhost', $port = 8080, $address = '127.0.0.1', LoopInterface $loop = null, array $sslContext = null) {
public function __construct($httpHost = 'localhost', $port = 8080, $address = '127.0.0.1', LoopInterface $loop = null) {
if (extension_loaded('xdebug')) {
trigger_error('XDebug extension detected. Remember to disable this if performance testing or going live!', E_USER_WARNING);
}
@ -76,10 +75,6 @@ class App {
$socket = new Reactor($address . ':' . $port, $loop);
if (is_array($sslContext)) {
$socket = new SecureReactor($socket, $loop, $sslContext);
}
$this->routes = new RouteCollection;
$this->_server = new IoServer(new HttpServer(new Router(new UrlMatcher($this->routes, new RequestContext))), $socket, $loop);

View File

@ -52,15 +52,11 @@ class IoServer {
* @param \Ratchet\MessageComponentInterface $component The application that I/O will call when events are received
* @param int $port The port to server sockets on
* @param string $address The address to receive sockets on (0.0.0.0 means receive connections from any)
* @param array $sslContext An array of PHP stream context options in order to support SSL
* @return IoServer
*/
public static function factory(MessageComponentInterface $component, $port = 80, $address = '0.0.0.0', array $sslContext = null) {
public static function factory(MessageComponentInterface $component, $port = 80, $address = '0.0.0.0') {
$loop = LoopFactory::create();
$socket = new Reactor($address . ':' . $port, $loop);
if (is_array($sslContext)) {
$socket = new SecureReactor($socket, $loop, $sslContext);
}
return new static($component, $socket, $loop);
}