swoole / swoole-src

🚀 Coroutine-based concurrency library for PHP
https://www.swoole.com
Apache License 2.0
18.42k stars 3.16k forks source link

Http Server - SWOOLE_HOOK_TCP - stream_socket_enable_crypto() #4909

Open smathersPersonal opened 1 year ago

smathersPersonal commented 1 year ago

Hi there, Love the project. Ran into a bit of an issue and I'm stumped.

Thanks!!

Server Info:

Swoole => enabled
Author => Swoole Team <team@swoole.com>
Version => 5.0.1-dev
Built => Nov 16 2022 22:29:32
coroutine => enabled with boost asm context
epoll => enabled
eventfd => enabled
signalfd => enabled
cpu_affinity => enabled
spinlock => enabled
rwlock => enabled
openssl => OpenSSL 1.1.1f  31 Mar 2020
dtls => enabled
http2 => enabled
json => enabled
pcre => enabled
zlib => 1.2.11
mutex_timedlock => enabled
pthread_barrier => enabled
futex => enabled
async_redis => enabled

Directive => Local Value => Master Value
swoole.enable_coroutine => On => On
swoole.enable_library => On => On
swoole.enable_preemptive_scheduler => Off => Off
swoole.display_errors => On => On
swoole.use_shortname => On => On
swoole.unixsock_buffer_size => 8388608 => 8388608
Linux d-ivr01 5.15.0-1022-aws #26~20.04.1-Ubuntu SMP Sat Oct 15 03:23:19 UTC 2022 aarch64 aarch64 aarch64 GNU/Linux
PHP 8.0.3 (cli) (built: Jan 20 2022 03:43:11) ( NTS )
Copyright (c) The PHP Group
Zend Engine v4.0.3, Copyright (c) Zend Technologies
    with Zend OPcache v8.0.3, Copyright (c), by Zend Technologies
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/aarch64-linux-gnu/9/lto-wrapper
Target: aarch64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 9.4.0-1ubuntu1~20.04.1' --with-bugurl=file:///usr/share/doc/gcc-9/README.Bugs --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,gm2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-9 --program-prefix=aarch64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-libquadmath --disable-libquadmath-support --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --enable-fix-cortex-a53-843419 --disable-werror --enable-checking=release --build=aarch64-linux-gnu --host=aarch64-linux-gnu --target=aarch64-linux-gnu
Thread model: posix
gcc version 9.4.0 (Ubuntu 9.4.0-1ubuntu1~20.04.1)
Draghmar commented 1 year ago

I run into the same issue, also with SES. I was wandering if it's related to the Swoole and some hook. The only difference for me is using task for sending. But the smtp log looks exactly the same.

matyhtf commented 1 year ago

SMTP uses the startSSL feature to dynamically enable encryption. There may be some problems with swoole hook support here. I am working to fix it

TorstenDittmann commented 11 months ago

Running into the same issue 👍🏻

ging-dev commented 4 months ago

Looking forward to this feature

Draghmar commented 3 months ago

@matyhtf Hey, do you think there's a chance to get this fixed? I'm asking because I suddenly got task to do where I will need to send e-mail from within api. Up until now I've manage to mitigate this by sending e-mail from different env. Now it won't be possible. So I'd love to be able to send this without have to find some quirk workaround. ;)