1

The reason why I'm asking this is that the encryption leaves up to a length of 143 characters to be used as filename. While normally it doesn't seem like a trouble, it becomes one when the name of a file contains many multi-byte CJK (Chinese, Janpanese, Korean) characters.

However, I wasn't able to manually rename the file, because it was supposed to be downloaded and processed internally by a program. Specifically, it is the resume file used by Transmission, which should be stored under ~/.config/transmission/resume directory.

As I do know in which folder the file will be stored (in this case, the aforementioned resume folder), I'd like to unencrypt this specific folder to solve the "filename too long" issue.

So my question is, aside from unencrpting the entire home folder, is there a way to unencrypt only one specific folder/directory?

Naitree
  • 439

2 Answers2

2

I don't know a way to do exactly what you ask; but you could create a folder elsewhere and mount it within your home folder, which would solve the problem.

I do this with à second hdd, mounted as '/home/mark/media', so as not to fill my ssd with photos & music.

For example, create a folder in

/media/example and mount it by adding a link

ln /media/example /home/mark/example

This will then persist over reboots. If it's a while partition it's better to add it to fstab

  • Thanks you. I moved the folder to under /home and linked it back into ~/.config, which solved my problem. – Naitree Jan 30 '15 at 17:49
1

If you could decrypt or mount just on single file, it would use the same keys as all the other encrypted files, so I'm not seeing an advantage over just mounting the encrypted home regularly.

If you wanted to create another unencrypted folder anywhere else to store the ~/.config/transmission/resume directory, or the whole ~/.config/transmission you could do a bind mount:

mount --bind olddir newdir

and wouldn't need to use a separate partition or drive, could put the newdir in / or /home or anywhere.

Xen2050
  • 8,705
  • Thanks for your solution. For some reason I do not know, it didn't work for me. I bind-mounted ~/.config/transmission with /home/TooLong/transmission. Afterwards, I logged out but couldn't log in again. Then I rebooted system and logged in, finding out /home/TooLong folder became empty. – Naitree Jan 30 '15 at 17:56
  • hmmm, the bind mount there would only last until a reboot (or a umount) without some config changes, probably tricky with home encrypted too. if the ln works that's even better – Xen2050 Jan 31 '15 at 03:12