Get root privileges for nautilus on sftp connection

Hya, bad news for you. The short answer is that you can't — you get the privileges of the user you logged in as.

The long answer follows herewith… The 'connect to server' option is nothing but a pretty gui that issues simple sftp commands under the hood, once connected to a server via an ssh like transport protocol. A list of these commands is available if you enter a terminal window and enter man sftp. You'll see the commands available to 'connect to server' in the section 'interactive commands' of the manpage.

They are limited to bye cd chgrp chmod chown df exit get help lcd lls lmkdir ln lpwd ls lumask mkdir progress put pwd quite rename rm rmdir symlink and !. You may recognise many of them from ftp, if you ever command-line ftp'd. Some new cool additions, but as you can see none of them supports the concept of RunAs, or sudo.

Gaining elevated privileges was simply never designed into the protocol.