Back to Home
joey-zhou icon

xiaozhi-esp32-server-java

by joey-zhou

Overview

Provides backend support and a management platform for smart hardware devices, focusing on AI-powered voice interaction, device management, and IoT control.

Installation

Run Command
docker-compose up -d

Environment Variables

  • WECHAT_APPID
  • WECHAT_SECRET
  • SMS_ALIYUN_ACCESS_KEY_ID
  • SMS_ALIYUN_ACCESS_KEY_SECRET
  • SMS_ALIYUN_SIGN_NAME
  • SMS_ALIYUN_TEMPLATE_CODE
  • EMAIL_SMTP_USERNAME
  • EMAIL_SMTP_PASSWORD
  • SPRING_DATASOURCE_URL
  • SPRING_DATASOURCE_USERNAME
  • SPRING_DATASOURCE_PASSWORD
  • SPRING_REDIS_HOST
  • SPRING_REDIS_PORT
  • SPRING_REDIS_PASSWORD
  • SPRING_REDIS_DATABASE
  • XIAOZHI_UPLOAD_PATH
  • VAD_MODEL_PATH

Security Notes

A critical security vulnerability exists in `WebSocketHandler.java` where device authentication is commented out, allowing any device with a known `device-id` to connect without a valid token. The frontend code (`web/src/utils/jsencrypt.ts`) contains hardcoded RSA public and private keys, which is a significant client-side security risk if used for anything beyond local storage convenience. File upload functionality (`FileUploadController.java`) allows configurable upload paths, which could be exploited for arbitrary file writes if the target directory is not properly secured on the server. The application uses Spring Security/Sa-Token for API authentication, which is generally good, but this does not cover the unauthenticated WebSocket endpoint.

Similar Servers

Stats

Interest Score100
Security Score2
Cost ClassMedium
Avg Tokens300
Stars1093
Forks405
Last Update2026-01-13

Tags

Smart HomeIoTAI Voice AssistantSpring BootWebSocket