On 09/01/2022 04:13, shimi wrote:
On Sat, 8 Jan 2022, 13:24 Shachar Shemesh, <shac...@shemesh.biz> wrote:

You can probably find it under /proc/$SSH_AGENT_PID/fd.


With that said, I'm not sure whether that brings you any closer to recovering it. Maybe a move (the syscall, not the command line) from there to $SSH_AUTH_SOCK?

Wouldn't ln -s /proc/$SSH_AGENT_PID/fd/<socket fd> $SSH_AUTH_SOCK achieve the /purpose/ of the OP (even if without actually creating a socket file)? Assuming I understand correctly the purpose...

The permissions are all wrong for the task. The directory only has X permission for root (which disqualifies this solution right there and then), and the file itself too.


Now, files under proc don't necessarily behave the way their permissions suggest they should (hence my suggestion to use the rename syscall. It does not, normally, work across filesystems, but it might in this case). In this case, however, you really don't have access as a normal user.


Shachar


_______________________________________________
Linux-il mailing list
Linux-il@cs.huji.ac.il
http://mailman.cs.huji.ac.il/mailman/listinfo/linux-il

Reply via email to