Re: link_path_walk/dentry_path_raw TOCTTOU race question

2018-07-24 Thread riya khanna
ntry path full_path = d_path(_path, buf, PATH_MAX); if (strcmp(exclude, full_path) == 0) { ret = -EACCES; goto out; } ... // clean up } On Tue, Jul 24, 2018 at 6:32 PM, wrote: > On Tue, 24 Jul 2018 16:59:27 -0400, riya khanna said: > > > I'm trying to und

link_path_walk/dentry_path_raw TOCTTOU race question

2018-07-24 Thread riya khanna
Hi, I'm trying to understand what prevents TOCTTOU race conditions in dentry_path_raw and link_path_walk? What happens when somebody points a symlink path component from a dir that has the attacker is allowed to read to a dir that they are not allowed to read while link_path_walk() is doing its

Re: FW: wrapper device driver

2015-02-03 Thread riya khanna
On Mon, Feb 2, 2015 at 9:15 PM, Greg KH g...@kroah.com wrote: On Mon, Feb 02, 2015 at 05:50:43PM -0600, riya khanna wrote: On Mon, Feb 2, 2015 at 5:00 PM, Greg KH g...@kroah.com wrote: On Mon, Feb 02, 2015 at 04:46:24PM -0600, riya khanna wrote: The goal is to provide multiple instances

wrapper device driver

2015-02-02 Thread riya khanna
Hi, I'm writing a device driver to to provide a wrapper device around a real device. Is it acceptable to do the following: wrapper_dev_open(flags) { // do additional bookkeeping real_dev_filp = filp_open(real_device_node_path, flags); } wrapper_dev_mmap(mmap_parameters) { // do

Re: wrapper device driver

2015-02-02 Thread riya khanna
struct real_dev-f_op would not be made available to the userspace. It's for target/real device bookkeeping. On Mon, Feb 2, 2015 at 4:02 PM, valdis.kletni...@vt.edu wrote: On Mon, 02 Feb 2015 15:24:37 -0600, riya khanna said: Hi, I'm writing a device driver to to provide a wrapper device

Re: FW: wrapper device driver

2015-02-02 Thread riya khanna
I guess a userspace library approach won't be transparent to the applications. On Mon, Feb 2, 2015 at 3:44 PM, Malte Vesper malte.ves...@postgrad.manchester.ac.uk wrote: From: Malte Vesper Sent: 02 February 2015 21:43 To: riya khanna Subject: RE

Re: FW: wrapper device driver

2015-02-02 Thread riya khanna
, riya khanna wrote: I guess a userspace library approach won't be transparent to the applications. Look at cuse, I think it provides what you are wanting to do here. But as you really didn't say what your goals are, it's hard to determine. good luck, greg k-h

Re: FW: wrapper device driver

2015-02-02 Thread riya khanna
On Mon, Feb 2, 2015 at 5:00 PM, Greg KH g...@kroah.com wrote: On Mon, Feb 02, 2015 at 04:46:24PM -0600, riya khanna wrote: The goal is to provide multiple instances of a real device, where each instance could be assigned to a container. This is to enable support for device multiplexing

Re: FW: wrapper device driver

2015-02-02 Thread riya khanna
On Mon, Feb 2, 2015 at 8:49 PM, valdis.kletni...@vt.edu wrote: On Mon, 02 Feb 2015 17:50:43 -0600, riya khanna said: The purpose of multiplexing is to either block undesired events/operations on devices (e.g. input, graphics) or respond to the applications based on the in-memory state

Shared mapping

2015-01-12 Thread riya khanna
Hi, Is there a way, w.r.t memory contents, to make a process B see what process A sees through shared memory mappings? Suppose Process A has mapped a device file (say F) at address 0x in its address space. Is it possible for process B to see the same device file F contents as process A

Re: Shared mapping

2015-01-12 Thread riya khanna
, Jan 12, 2015 at 2:08 AM, riya khanna riyakhanna1...@gmail.com javascript:; wrote: Hi, Is there a way, w.r.t memory contents, to make a process B see what process A sees through shared memory mappings? Suppose Process A has mapped a device file (say F) at address 0x in its

Re: Shared mapping

2015-01-12 Thread riya khanna
...@vt.edu wrote: On Mon, 12 Jan 2015 07:34:41 -0600, riya khanna said: Suppose A and B have mapped the same physical memory or shmem file. I want a way to make process A forcefuly revoke/remap the existing shared memory mappings in process B, so that B sees whatever A does. Umm..B should

Re: remote devices

2014-06-02 Thread riya khanna
client machine itself. NFS operations are not used to override device files here. How about using iSCSI and all for devices? Maybe you can tell something more about what you are trying to do? Regards, On Thu, May 29, 2014 at 10:53 PM, riya khanna riyakhanna1...@gmail.com wrote: Hi, I'm

remote devices

2014-05-31 Thread riya khanna
Hi, I'm trying to access remote devices locally by mounting/exporting /dev nodes over NFS. However, looks like the access requests are treated local based on major minor numbers (e.g. cat /mnt-dev-over-nfs/kmg output is same as cat /dev/kmsg) How can I change this behavior? and if it is at all