nickola / web-console Goto Github PK
View Code? Open in Web Editor NEW:desktop_computer: Simple web-based shell in your browser (outdated)
Home Page: https://nickola.ru/projects/web-console
:desktop_computer: Simple web-based shell in your browser (outdated)
Home Page: https://nickola.ru/projects/web-console
Not sure if this is still being supported or not but just grabbed the 0.9.7 release and I am getting a
Internal Server Error
syntax error, unexpected ','
took a look at the code no way for me to debug it.
I installed the web console and have it mostly working. However, I am struggling with some git commands at the moment. I can do some git commands through web console, like checking out branches and creating commits. For some commands I must use sudo but not all. Sadly, I have not been able to get a git push to work and I keep getting the following error:
Could not create directory '/var/www/.ssh'.
Host key verification failed.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
When executing a git push, it does not even take me to a login for the remote. Not sure where to go from here but any help would be greatly appreciated. Thanks!
I would like to access the prompt immediately without login and without aunthentication. How do I bypass the login?
Firstly, love this! Awesome work guys 👍
Question:
Are you able to authenticate using a public key, specifically for us it's a .ppk file?
Thanks!
Integrated omniauth into our web app successfully. Omniauth connects and sends a notification to a gmail address that gmail has connected to the app. But when I click on my gmail account, it goes to a generic "An error has occurred" message.
Commented out gems one by one in the development section of Gemfile until error messages began appearing on logs. It was found that web-console gem is causing this error to come up. It is possible that default rails methods were overwritten at some point.
The first time load, keyboard is shows.
but after I hide the kyeboard, i can not input anymore until i refresh the browser..
Is it possible to have this run under an alternate bash environment. I am attempting this with alias and the script placed in individual user directories (this works great). I use LShell to limit a user bash environment. However, I am noticing that the users ... even though not granted sudoers permissions ... are having to type sudo blah blah
before simple commands (ex: mkdir SOMEDIRECTORY) it then adds root privileges to the newly created directory.
Users must then sudo chown -R username:www-data SOMEDIRECTORY
to get access back to the directory. If not changed users attempt to enter with say (ftp) and cannot due to the obvious permissions.
Is there a way for web console to understand the user and their home directory and not require sudo privs to create and additionally (and at the very least) create the directories and/or files with the users own permissions?
Another minor issue is that users can easily grep running processes and view what everyone under that particular application is using. So if you have an application that mounts itself to individual users, a user can grep this process and gather all usernames on the server running the process.
This is just another solid example why it would be spectacular to have users assigned a limited environment. At which point they will only be able to see their running processes etc.
Other than these issues... the application looks wonderful and I hope that development does continue. Thanks for your hard work! 😄
Example of an added function within the webconsole.php
$ENV_PATH = ':/usr/local/bin:/usr/sbin';
Giving us the ability to name environment paths for non-sudo users.
Also, would it be possible to add in permitted commands - rather than requiring pseudo privileges for everything?
Hi!
I got this error message when trying to run for example top.
Can you please help me out?
Thanks!
I updated webconsole.php but the shell prompt keeps on saying "Wrong password try again"
Anything that I might be missing. As far as I understand, its just putting that one file into web server's root and the file should have the credentials provided as values to $USER and $PASSWORD for the login to work.
Could you please suggest?
I modifed the webconsole.php and uploaded to a webserver - to the /var/www directory
and put the url -- http://IP/webconsole.php and it didnt work. I have apache - what else i need to do ?
`534 <?php
535 // Initializing
536 if (!isset($NO_LOGIN)) $NO_LOGIN = false;
537 if (!isset($ACCOUNTS)) $ACCOUNTS = array();
// ==============================================================
538 if (!isset($PASSWORD_HASH_ALGORITHM)) $PASSWORD_HASH_ALGORITHM = '';
539 if (isset($USER) && isset($PASSWORD) && $USER && $PASSWORD){
540 $ACCOUNTS[$USER] = $PASSWORD_HASH_ALGORITHM ? get_hash($PASSWORD_HASH_ALGORITHM, $PASSWORD) : $PASSWORD;
541 }
// ==============================================================
542 if (!isset($HOME_DIRECTORY)) $HOME_DIRECTORY = '';
543 $IS_CONFIGURED = ($NO_LOGIN || count($ACCOUNTS) >= 1) ? true : false;`
I am unable to copy or even select the text that is outputted to the console when using Chrome. However, when using FireFox it works just fine. I was about to open an issue on jQuery.terminal but figured I should stop by here before asking them to fix something that might not be their fault.
Overall, great project! Really saved me a couple headaches and mental spasms while working on a server without real SSH access.
Keep it up!
I'd like to run the command after login. It's possible
Hello, I would like to ask, I cloned the project to my server, but also modify the webconsole.settings.php file account password, but access to the webconsole.php is not any output
Hi !
Very great plug to get access via web to ssh.
But I can't use it to open vi. Could you help me to get that ?
The keyboard typing doesn't echo.
If I run the following in Web Console...
php -r 'echo "PHP Path : ".PHP_BINARY;'
Expected result...
PHP Path : /usr/bin/php7.0
Actual result...
PHP Path :
If I then run the following in Web Console...
/usr/bin/php7.0 -r 'echo "PHP Path : ".PHP_BINARY;'
I get...
PHP Path : /usr/bin/php7.0
If I then run the following via SSH on the server as the web user (It is a docker container fresh Ubuntu image)...
php -r 'echo "PHP Path : ".PHP_BINARY;'
I get...
PHP Path : /usr/bin/php7.0
The server has a number of symbolic links involved in the PHP look up but ultimately it is just a standard PHP7 APT Ubuntu install...
$ ls -la /usr/bin/php
lrwxrwxrwx 1 root root 21 Nov 20 15:26 /usr/bin/php -> /etc/alternatives/php
$ ls -la /etc/alternatives/php
lrwxrwxrwx 1 root root 15 Nov 20 15:26 /etc/alternatives/php -> /usr/bin/php7.0
$ ls -la /usr/bin/php7.0
-rwxr-xr-x 1 root root 4430896 Aug 9 14:43 /usr/bin/php7.0
hi,
i got webconsole running (same user as lighttpd=www-data)
now i try to connect to localhost via ssh:
user@bananapi /$ ssh -tt -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no frank@localhost
Warning: Permanently added 'localhost' (ED25519) to the list of known hosts.
Permission denied, please try again.
Permission denied, please try again.
Permission denied (publickey,password).
tried with -v param to ssh:
debug1: Next authentication method: password
debug1: read_passphrase: can't open /dev/tty: No such device or address
debug1: Authentications that can continue: publickey,password
Permission denied, please try again.
debug1: read_passphrase: can't open /dev/tty: No such device or address
debug1: Authentications that can continue: publickey,password
Permission denied, please try again.
debug1: read_passphrase: can't open /dev/tty: No such device or address
debug1: Authentications that can continue: publickey,password
debug1: No more authentication methods to try.
Permission denied (publickey,password).
it seems that the problem exists because it's not a real terminal...
any idea to get it working?
Regards Frank
Can I open Web Console in a new tab with predefined login and password? So, I need user be logged in after console opened.
How to fix it?
I want to access all the machines in the LAN through web-console, how to manage multiple machines through web-console?
Hello,
When I try to connect to my server by ssh I get this :
Host key verification failed.
With the argument -t :
[Private things before (my IP, port....)
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_rsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file /var/www/.ssh/id_ed25519-cert type -1
debug1: Enabling compatibility mode for protocol 2.0
debug1: Local version string SSH-2.0-OpenSSH_7.2p2 Ubuntu-4ubuntu2.1
debug1: Remote protocol version 2.0, remote software version OpenSSH_7.2p2 Ubuntu-4ubuntu2.1
debug1: match: OpenSSH_7.2p2 Ubuntu-4ubuntu2.1 pat OpenSSH* compat 0x04000000
debug1: Authenticating to 89.234.183.98:45608 as 'dlazzy'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: [email protected]
debug1: kex: host key algorithm: ecdsa-sha2-nistp256
debug1: kex: server->client cipher: [email protected] MAC: <implicit> compression: none
debug1: kex: client->server cipher: [email protected] MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ecdsa-sha2-nistp256 SHA256:uwRrnLYnHkff93V+K7j9y9/gZONX3PHbxhTiE9cWN/U
debug1: checking without port identifier
debug1: read_passphrase: can't open /dev/tty: No such device or address
Host key verification failed.
thanks !
When I use SSH to access the console on my web server with the web account and I do:
git --version
I get v2.15.1
When I do it from the console I get v1.8.3.1
Why are the versions different? I checked "id" and it's the same account, just different results based on where I execute it from.
Didn't test but you're using outdated version (as submodule) of jQuery Terminal that detect Google Chrome to attach scroll to html when terminal is added to body. And google change behavior and it's now like in other browsers.
If you update jQuery Terminal the issue will be resolved.
Hi, I used username root and password but I got $ instead of #. so, I am not root, I can't even login to my /var/www folder and I can't change permissions, etc.
what is purpose of webconsole if I am just a user and not admin?
I wanted to use webconsole because suddenly my vps refuse 443 port, therefore I can't use shell in a box to administrate my vps, I wanted to see what is problem.
simple example, when I was ping on server it doesn't show the output simultaneously. I must wait until the process is finish. Can you update this issue? Regards, thanks before
.
login: root
password: *******
Wrong password try again!
login: user
password: *******
Wrong password try again!
This error's I get for both encryption types. Can you help me to resolve problem?
done install webconsole, done install vendor package as well as below
[root@localhost src]# ls -la vendor/
total 0
drwxr-xr-x 7 root root 105 Feb 19 2014 .
drwxr-xr-x 7 root root 196 Jan 13 07:50 ..
drwxr-xr-x 2 root root 64 Dec 25 20:39 eazy-jsonrpc
drwxr-xr-x 2 root root 23 Feb 19 2014 jquery
drwxr-xr-x 3 root root 192 Dec 25 20:50 jquery.mousewheel
drwxr-xr-x 6 root root 276 Dec 25 20:46 jquery.terminal
drwxr-xr-x 2 root root 182 Dec 25 20:51 normalize
but, no success so far...
I always got this error when open web-console via web-browser
[email protected] ~$ id
[ERROR] Access denied (no authentication token found)
ANyone care to help, please, thanks.
I would ask this through forum or something, but dont see anything like that available.
Was wondering about the best way to close off a server to everything but https traffic, and then allow "login" via webconsole over https, instead of also running externally visible sshd
To be precise: rather than prompt for a "username and password" that is embedded in the script, prompt for actual unix level username and password.. and then give a tty session as THAT user, rather than the web user.
Maybe this could be added to the FAQ?
When I move through folders using command "cd", doesn´ t seem to work, because "ls" command always shows home folder. It seems to happen with both versions 0.9.5 and 0.9.7.
This is more a documentation bug report as a bug itself.
I'd highly appreciate if you could stop offering web-console as a tool for "Web-based SSH", for the simple reason that it doesn't have anything to do with the SSH protocol, and while "SSH" stands for "secure shell", web-console isn't offering a shell at all. I already know that you address a little bit about this topic in your FAQ, however the basic tagline of your tool is still simply wrong.
This is obviously quite confusing for a lot of your users that expect scrolling output, want to login using public keys, expect a working terminal, want to change their environment or use interactive tools, to name just a few examples.
I'm not saying web-console isn't useful; advertising it as "Web-based SSH" however is blatantly wrong and triggers a whole bunch of wrongful expectations, and while it simulates being a shell, it behaves absolutely counter-intuitive compared to any real shell. Look at this trivial example where I want to modify an environment variable:
login: jonas
password: *****
You are authenticated
user@[...] ~$ echo $PATH
/usr/local/bin:/usr/bin
user@[...] ~$ export PATH=/here/is/another/path:/usr/local/bin:/usr/bin
user@[...] ~$ echo $PATH
/usr/local/bin:/usr/bin
I won't call this a bug because I already understand that web-console is basically firing one-shots which run each in their own shell, with no sense of a persistent "environment". But this is what people are expecting if you promise them "SSH".
Please stop advertising web-console in this way.
At the moment, the console window doesn't trigger an iPad's soft keyboard, so the app isn't useable in those contexts. I assume this would apply to other mobile devices as well.
Hello,
I want to open webconsole in a subdomain, but without typing in the URL the webconsole.php.
Example like its now:
webconsole.xxx.de/webconsole.php
Example how I want that it works:
webconsole.xxx.de/
Hope you can help me
thanks
Hello, I would like to use web-console to be able to access the console of an external server but could not configure it to connect to another server.
I would like to know if it is possible to use web-console as if it were Putty.
Hi,
I'm trying connect another computer through ssh... but i receive this error:
[email protected] ~$ sudo ssh -o StrictHostKeyChecking=no -t -t [email protected]
Permission denied, please try again.
Permission denied, please try again.
Permission denied (publickey,password).
I already edit my /etc/sudoers inserting this line:
www-data ALL=(ALL) NOPASSWD: ALL
[email protected] ~$ sudo id
uid=0(root) gid=0(root) groups=0(root)
How can I access another host through ssh using Web Console?
Thanks
It was fine, but now:
[ERROR] AJAX: Invalid JSON
Server reponse:
Can't execute command.
Hi.
is it possible to build up a list of commands that the user can't run ?
eg vi, tail etc and show 'unsupported command' on screen ?
Thanks
how do i fixed this in shared hosting?
Hello!
Please increase ajax timeout to 10 hours.
Thanks
Hi
is it possible to set a color to be shown for directories.
Then when you ls, you can see what is a file and what is a directory ?
Thanks
I've setuped my
$HOME_DIRECTORY = '/home/nix/';
This is the usage example :
login: nix
password: *****
You are authenticated
[email protected] /home/nix/$ ls
Unable to change directory to current working directory, updating current directory
[email protected] /usr/share/nginx/html$
Если попытаться открыть файл через nano, то консоль виснет, а проц получит полную загрузку 1-го ядра, это как то можно исправить?
Debian9 + php 7.0
I have a hostgator shared account.
In my .bashrc i have:
alias php='/opt/php71/bin/php'
alias composer='/home/XXX/bin/composer.phar'
In webconsole, when I try to run:
php -v
I got:
Content-Type: application/json
Access-Control-Allow-Origin: *
Access-Control-Allow-Headers: x-requested-with, content-type
{"jsonrpc":"2.0","id":null,"error":{"code":-32700,"message":"Parse error","data":null}}
or when I try to run:
composer -v
I got:
sh: composer: command not found
Would it be possible to flush output continuously to the browser?
I run for example a tar or rsync command with verbose output. But that is only shown when the process is completed. This way there is no indication that all is still good...
I have packaged your app for my Synology. I.e.: it's now running "windowed" within DSM (Synology's Desktop) as any third party package.
As I already had to log in the DSM, I would like to remove the need to login in the Web Console. But I don't know if there is an easy trick for that (some settings ?). Or do I have to find and remove all the code prompting for user/password ? (code that I am not able so far to find :/ )
Trying to use it from latest Safari seems to just blink and fail. Any ideas?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.