开发环境:
前端:Vue+Stompjs
后端:Rabbitmq Web Stomp Plugin
Rabbitmq安装插件:[rabbitmq_management,rabbitmq_mqtt,rabbitmq_stomp,rabbitmq_web_mqtt,rabbitmq_web_mqtt_examples,rabbitmq_web_stomp,rabbitmq_web_stomp_examples].
硬件环境:使用的阿里云windos server2008系统
阿里云中下载pfx证书。使用如下的代码转化成Rabbitmq需要配置的证书:
提取ca证书:
openssl pkcs12 -in 4000000_www.xxxx.com.pfx -nodes -password pass:域名证书密码 -nokeys -cacerts -out cacert.pem
提取server证书:
openssl pkcs12 -in 4000000_www.xxxx.com.pfx -nodes -password pass:域名证书密码 -nokeys -clcerts -out cert.pem
提取私钥(密码:123456)
openssl pkcs12 -in 4000000_www.xxxx.com.pfx -nodes -password pass:123456 -passout pass:123456 -nocerts -out private_key.pem
配置rabbitmq.conf文件需要配置如下内容: