PDA

Bekijk de volledige versie : FTP problem with user-access



Ashutor
30-01-2008, 13:50
Hi guys,

I have now searched the forum for a couple of days, and I just can't seem to find the answers I am looking for.

The problem I have is this:
Last week I wanted to change the password on my normal user on the router (uses KFurge firmware, at that time 1.0.4.6).
So I deleted my user through the webinterface and made it again with a new password (not that good at the commandline ;o))

I went back in through Telnet with root and remade the changes to /etc/passwd file, that the user previously had.

Then the SSH access worked perfect again (for the user), no problem there BUT!
When I try and FTP onto the router, I get the error 226 Transfer done (but failed to open directory). I do not get the lists of files for this user.
If I FTP onto the router with one of the other users that I havent "remade", it works fine.
So I'm guessing, that some file used by the FTP-server dident get the "delete-user" and "remake-user" quite right?

It hasent got anything to do with PASV-mode, since it works for the "old" users. Also if I make a new user, it works fine. This is only a problem with the user I remade.

I have looked through the passwd file, and it seems to be just right...
Can you Gent's give me a clue :-)

Thanks in advance.
-Ash

kfurge
02-02-2008, 02:12
As long as the UID (user ID) and GID (group ID) were put back and there's nothing wrong with the passwd file, then everything should work OK. Are you *sure* you put the passwd file entry back the way it was supposed to be?

- K.C.

Ashutor
04-02-2008, 07:45
Well... I am pretty sure that I put it back the way it was... But since you ask, I can not be 100% sure.

Lets say, purely hypothetically ofcourse ;o), that I did not get the UID or GID right. Can I recover the right ID's from some other files that might use them?

- Ash.

kfurge
04-02-2008, 19:50
Lets say, purely hypothetically ofcourse ;o), that I did not get the UID or GID right. Can I recover the right ID's from some other files that might use them?


Yes. Look at any file known to have been created by the other user and do "ls -l <file>". Two of the columns are the UID and GID. Look up the ls manpage for specifics. If you didn't get it right, just modify the passwd file to fix.

- K.C.