Coder Social home page Coder Social logo

trojan-manager's People

Contributors

greaterfire avatar iamindian avatar k4yt3x avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

trojan-manager's Issues

Is this project still be maintained?

I have intalled trojan server and client , they both run well with default password which is without mysql auth.
When I finished to config mysql , created user and quota, the auth module did not work !
Now I can only use the global default password.

The operation doc is https://trojan-gfw.github.io/trojan/authenticator .

[trojan]> show quota
+----+----------+----------------------------------------------------------+---------------+----------+--------+
| ID | Username | Password | Quota | Download | Upload |
+----+----------+----------------------------------------------------------+---------------+----------+--------+
| 8 | myusername | b4fff45290308abcc96f0aca235703659b7b077c62cb22897e6ebb77 | 1073741824000 | 0 | 0 |
+----+----------+----------------------------------------------------------+---------------+----------+--------

Part of /usr/src/trojan/server.conf :
"mysql": {
"enabled": true,
"server_addr": "127.0.0.1",
"server_port": 3306,
"database": "trojan",
"username": "trojan_mysql", // yeah, i changed the db username
"password": "mypassword",
"key": "",
"cert": "",
"ca": ""
}

Part of Client/config.json
"password": [
"mypassword" // just the same as password in /usr/src/trojan/server.conf
],

Did I make something wrong?

can not add user successfully (got an issue with mysql)

Ubuntu 19.04,
Python 2.7.16, Python 3.7.3,
pip 19.1.1 from /usr/local/lib/python2.7/dist-packages/pip (python 2.7)
pip 18.1 from /usr/lib/python3/dist-packages/pip (python 3.7)
mysql Ver 14.14 Distrib 5.7.26, for Linux (x86_64) using EditLine wrapper

all the requirements have been successfully installed


the script use python3, but MySQLdb is not supported by python3

python3 trojan_manager.py int
Traceback (most recent call last):
  File "trojan_manager.py", line 19, in <module>
    import MySQLdb
ModuleNotFoundError: No module named 'MySQLdb'

try to use pymysql instead:

import pymysql
pymysql.install_as_MySQLdb() 

then successfully get in

but when I've added a user, quit, and query again, there's nothing in the database

journalctl -u mysql
Aborted connection to db: 'trojan' user: 'trojan' host: 'localhost' (Got an error reading communication packets)

sorry for the poor english

add users dosent work

the add user command not working,i think you forgot to uncomment the 151 line.
self.connection.commit() !?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.