Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Password generator sends password to external service #1225

Open
MichalKowalczyk opened this issue Aug 26, 2024 · 1 comment
Open

Password generator sends password to external service #1225

MichalKowalczyk opened this issue Aug 26, 2024 · 1 comment

Comments

@MichalKowalczyk
Copy link

Password generator linked in docs: tinyfilemanager.github.io/docs/pwd.html sends requests with our passwords in the URL parameters:
https://tinyfilemanager.alwaysdata.net/pwd.php?callback=jQuery3215432994212342044_1733443351&pwd=my_secred_password&_=272329541252

This is a significant vulnerability.

Is it really necessary to send a password in the URL parameters to an external service? This practice poses a serious risk of a data leak.

@devnull4242
Copy link

devnull4242 commented Aug 30, 2024

Yes i think the problem is:

$.ajax({
    type: "GET",
    url: "http://tinyfilemanager.alwaysdata.net/pwd.php",
    data: 'pwd='+pwd,
    dataType: 'jsonp',
    cache: false,
    // ...
});

I think a problem is that bcrypt is not supported in client side JavaScript. I do not like the user authentication in Tiny File Manager. I always deactivate it and use Htaccess from my browser. Htaccess can also use bcrypt. But it also supports e.g. SHA-256. That is not so good but it can be generated with JavaScript.

Also you can generate bcrypt and SHA-256/512 with htpasswd on linux client side:

bcrypt client generator:
htpasswd -B /path/to/.htpasswd username

crypt() client generator:
htpasswd -d /path/to/.htpasswd username

Interesting: http://tinyfilemanager.alwaysdata.net is a demo version of Tiny File Manager. But i can not found pwd.php there i think because it is hide in Tiny File Manager configuration e.g. with $exclude_items.

To be honest, it must be said that information about the server used by the user is not known. None of this helps an attacker very much.

In the end, it may be a trade-off. For example, bcrypt is very secure and generation is otherwise difficult for many users. But you could at least point this out on the page mentioned.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants
@MichalKowalczyk @devnull4242 and others