Linux sftp — how to add new user to access exist directory with write permission?
I have built a website and I can access and edit the website'files on server via the root user. The current file and directory structures are not changeable. Now I am hiring a webpage designer to help me re-design some pages, I am going to let the designer edit the files directly on the server. So I need to add a new user and restrict the new user to access only three front-end related directory. And the three directories are not in the same directory, like below:
The first step adding new user has been accomplished. But the problems are:
1 how to let the new user access above directories with write permission?
2 how to bind above three directories to the new user? (It seems ChrootDirectory can only bind one directory.)
I need to find all the files that have group Read or Write permission or files that have user write permission.
This is what I have so far:
find . -exec ls -l {} \; | awk '/-...rw..w./ {print $1 " " $3 " " $4 " " $9}'
It shows me all files where group read = true, group write = true... (5 Replies)
Hi,
The requirement is like,
the program needs 2 argument one is user_id and second one is directory path. My script will check if that user_id has write access to the directory path. The directory path may be in any file system like AFS or NFS.
Can any one please suggest some points to... (1 Reply)
RHEL5.0
As we know, when root create a new user, a new home directory will be created : /home/user
I want to know what determine the access permission of /home/user .
Thanks! (1 Reply)
Hi,
Im trying to add some validation into my shell script code that basically checks whether a directory exists before SFTP'ing a file to it. If the directory exists then it will add the file, if not then it should return some kind of message. This is the code I have written so far but with no... (1 Reply)
Guys, i wanna get any user files with write permission (on user or group permission) for review but i confuse with -perm parameter.
any body can help me to explain what is that mean?
thank's (1 Reply)
Hi
I am trying to make a web program which is command line equivalent. i have done the coding in cgi program in perl and html for basic forms to take inputs. when i ran the program from web application i see permission denied messages. after analyzing i found apache is running as wwwrun which... (2 Replies)
Hi folks,
I am trying to grant the access like below items using the setfacl command, but i couldn't achieve as what I required. any other possibility.
username : testing
Readonly access in /form_dl/system/prd/logs
Write only access in /form_dl/system/prd/deploy
No access to other... (0 Replies)
Hi All,
We have a scenario in production where we want only one user from a group to modify the file. The file is not set to write permission for application manager.
-r--r--r-- 1 amgr u00 15661716 Aug 30 00:06 DCI.dat
So here amgr will have permission to edit the file. We want a... (10 Replies)
logMsg='Started by '${USER}
LOG_MESSAGE "${logMsg}"
resultCode=$?
if ]; then
return ${resultCode}
fi
touch ${FILELISTPATH}
resultCode=$?
if ]; then
logMsg='failed to create file list:'${FILELISTPATH}
LOG_ERROR "${logMsg}" CUSTOM_PREPROCESS ${FATAL}
... (2 Replies)
Discussion started by: raka123
2 Replies
LEARN ABOUT DEBIAN
pure-quotacheck
pure-quotacheck(8) Pure-FTPd pure-quotacheck(8)NAME
pure-quotacheck - Update virtual quota files for Pure-FTPd
SYNTAX
pure-quotacheck -u username/gid -d home directory [-g group/gid]
DESCRIPTION
pure-quotacheck create a .ftpquota file in the specified directory.
This file contains the current file and size of the directory, and it is used by Pure-FTPd when virtual quotas are enabled.
It's recommended to periodically run pure-quotacheck for every user, in crontabs.
OPTIONS -d <directory>
Scans the specified <directory>.
-g <group or gid>
Sets the group files will be scanned as. This is optional : if a user name is passed to -u</fR>, group are automatically retrieved.
-u <user or uid>
Set the user name files will be scanned as. This is mandatory, and it can't be "root".
-h Output usage information and exit.
FILES
.ftpquota
EXAMPLES
To run this program the standard way type:
pure-quotacheck -u john -d /home/john
AUTHORS
Frank DENIS <j at pureftpd dot org>
SECURITY
pure-quotacheck switches real and effective uids/gids as soon as possible. Root privileges are never given back.
pure-quotacheck refuses to scan directories with uid = 0 (root) or gid = 0 (wheel/root) .
pure-quotacheck performs a chroot() call to the home directory. It never traverses parent directories.
pure-quotacheck only scans real files (no socket, no pipe, etc) .
pure-quotacheck enforces read access on directories to prevent against people doing chmod 0 before a quota scan.
pure-quotacheck enforces write access on the home directory to properly write the .ftpquota file.
pure-quotacheck never scans the same inode/device pair twice.
SEE ALSO ftp(1), pure-ftpd(8)pure-ftpwho(8)pure-mrtginfo(8)pure-uploadscript(8)pure-statsdecode(8)pure-pw(8)pure-quotacheck(8)pure-authd(8)
RFC 959, RFC 2228, RFC 2389 and RFC 2428.
Pure-FTPd team 1.0.36 pure-quotacheck(8)