mosquitto not authorised

Eclipse Mosquitto is an open source (EPL/EDL licensed) message broker that implements the MQTT protocol versions 5.0, 3.1.1 and 3.1. Mosquitto is lightweight and is suitable for use on all devices from low power single board computers to full servers.
The MQTT protocol provides a lightweight method of carrying out messaging using a publish/subscribe model. This makes it suitable for Internet of Things messaging such as with low power sensors or mobile devices such as phones, embedded computers or microcontrollers.
The Mosquitto project also provides a C library for implementing MQTT clients, and the very popular mosquitto_pub and mosquitto_sub command line MQTT clients.

最近需要用mqtt来实现消息处理,在windows上安装Mosquitto之后,不使用用户名密码提示connection refused: not authorised。结果添加用户名密码之后还是提示同样的错误。

Continue Reading

Python3 读取Chrome cookie

网上搜一下,读取cookie的基本都是这份代码。我也忘了是从那里抄来的了,这里贴一下 ,对于最新的chrome需要修改下路径:

# chrome 96 版本以下
# filename = os.path.join(os.environ['USERPROFILE'], r'AppData\Local\Google\Chrome\User Data\default\Cookies')
# chrome96 版本以上
# filename = os.path.join(os.environ['USERPROFILE'], r'AppData\Local\Google\Chrome\User Data\default\Network\Cookies')

Continue Reading