WinSCP and sudo /bin/bash1
I have been using WinSCP to connect, upload, and edit files to a secure Redhat Linux server for some time now. Recently it stopped working for some reason – I am able to connect, but I cannot upload or edit files like I used to. I think this is a
Log:
sudo
issue as I am getting the
I am able toerror 3: permission denied
sudo /bin/bash1
to root
using PuTTY. The only special setting I have (that worked before) is SCP/Shell>Shell: sudo bash1
. I have also tried sudo /bin/bash1
to no avail. Any ideas?
Log:
Bypass authentication: No Try agent: Yes; Agent forwarding: No; TIS/CryptoCard: No; KI: Yes; GSSAPI: No Ciphers: aes,blowfish,3des,WARN,arcfour,des; Ssh2DES: No SSH Bugs: -,-,-,-,-,-,-,-,- SFTP Bugs: -,- Return code variable: Autodetect; Lookup user groups: Yes Shell: sudo bash1 EOL: 0, UTF: 2 Clear aliases: Yes, Unset nat.vars: Yes, Resolve symlinks: Yes LS: ls -la, Ign LS warn: Yes, Scp1 Comp: No Local directory: C:\Users\webdev\Desktop, Remote directory: /var/www/html, Update: No, Cache: Yes Cache directory changes: Yes, Permanent: Yes DST mode: 1 -------------------------------------------------------------------------- Looking up host "xxxxxxxxxxxxxxx" Connecting to xxxxxxxxxxxxxx port 922 Server version: SSH-2.0-OpenSSH_4.3 Using SSH protocol version 2 We claim version: SSH-2.0-WinSCP_release_4.3.7 Doing Diffie-Hellman group exchange Doing Diffie-Hellman key exchange with hash SHA-1 Host key fingerprint is: ssh-rsa 2048 xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx:xx Initialised AES-256 SDCTR client->server encryption Initialised HMAC-SHA1 client->server MAC algorithm Initialised AES-256 SDCTR server->client encryption Initialised HMAC-SHA1 server->client MAC algorithm Using username "webdev". Prompt (7, SSH password, , &Password: ) Sent password Access granted Opened channel for session Started a shell/command -------------------------------------------------------------------------- Using SFTP protocol. Doing startup conversation with host. Type: SSH_FXP_INIT, Size: 5, Number: -1 Type: SSH_FXP_VERSION, Size: 5, Number: -1 SFTP version 3 negotiated. We believe the server has signed timestamps bug We will use UTF-8 strings for status messages only Limiting packet size to OpenSSH sftp-server limit of 262148 bytes Changing directory to "/var/www/html". Getting real path for '/var/www/html' Type: SSH_FXP_REALPATH, Size: 22, Number: 16 Type: SSH_FXP_NAME, Size: 47, Number: 16 Real path is '/var/www/html' Trying to open directory "/var/www/html". Type: SSH_FXP_LSTAT, Size: 22, Number: 263 Type: SSH_FXP_ATTRS, Size: 37, Number: 263 Getting current directory name. Listing directory "/var/www/html". Type: SSH_FXP_OPENDIR, Size: 22, Number: 523 Type: SSH_FXP_HANDLE, Size: 13, Number: 523 Type: SSH_FXP_READDIR, Size: 13, Number: 780 Type: SSH_FXP_NAME, Size: 4871, Number: 780 Type: SSH_FXP_READDIR, Size: 13, Number: 1036 Type: SSH_FXP_STATUS, Size: 28, Number: 1036 Status code: 1 Type: SSH_FXP_CLOSE, Size: 13, Number: 1284 Startup conversation with host finished. Copying 1 files/directories to remote directory "/var/www/html/" PrTime: Yes; PrRO: No; Rght: rw-r--r--; PrR: Yes (No); FnCs: N; RIC: 01; Resume: S (102400); CalcS: Yes; Mask: *.* TM: M; ClAr: No; CPS: 0; ExclM(No): AscM: *.*html; *.htm; *.txt; *.php; *.php3; *.cgi; *.c; *.cpp; *.h; *.pas; *.bas; *.tex; *.pl; *.js; .htaccess; *.xtml; *.css; *.cfg; *.ini; *.sh; *.xml File: "C:\Users\webdev\Desktop\test.php" Copying "C:\Users\webdev\Desktop\test.php" to remote directory started. Ascii transfer mode selected. Opening remote file. Type: SSH_FXP_OPEN, Size: 47, Number: 1539 Type: SSH_FXP_STATUS, Size: 24, Number: 1284 Discarding reserved response Type: SSH_FXP_STATUS, Size: 34, Number: 1539 Status code: 3, Message: 1539, Server: Permission denied, Language: Type: SSH_FXP_LSTAT, Size: 31, Number: 1799 Type: SSH_FXP_STATUS, Size: 29, Number: 1799 Status code: 2, Message: 1799, Server: No such file, Language: (ETerminal) Permission denied. Error code: 3 Error message from server: Permission denied Request code: 3 Asking user: Cannot create remote file '/var/www/html/test.php'. ("Permission denied. Error code: 3 Error message from server: Permission denied Request code: 3") (EScpSkipFile) Cannot create remote file '/var/www/html/test.php'. Permission denied. Error code: 3 Error message from server: Permission denied Request code: 3 Listing directory "/var/www/html". Type: SSH_FXP_OPENDIR, Size: 22, Number: 2059 Type: SSH_FXP_HANDLE, Size: 13, Number: 2059 Type: SSH_FXP_READDIR, Size: 13, Number: 2316 Type: SSH_FXP_NAME, Size: 4871, Number: 2316 Type: SSH_FXP_READDIR, Size: 13, Number: 2572 Type: SSH_FXP_STATUS, Size: 28, Number: 2572 Status code: 1 Type: SSH_FXP_CLOSE, Size: 13, Number: 2820