all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Org-mode and GPG (EasyPG)
@ 2009-07-23 19:09 Kyle Sexton
  2009-07-23 22:24 ` Eric S Fraga
  0 siblings, 1 reply; 10+ messages in thread
From: Kyle Sexton @ 2009-07-23 19:09 UTC (permalink / raw)
  To: org-mode

Currently I'm using org-mode with EasyPG and it works great.  Files
created with filename.org.gpg are automatically encrypted before being
saved, and it automatically knows to use org-mode for the file.

The one issue I'm having is with the Agenda view.  If I try to pull a
global agenda list and include encrypted files org-mode chokes because
it doesn't know to decrypt before hand.

This isn't a bug in org-mode by any means, but do other people have a
solution they've come up with for this?  Hopefully I'm not the only
one encrypting my note. :P

--
Kyle Sexton

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Org-mode and GPG (EasyPG)
  2009-07-23 19:09 Org-mode and GPG (EasyPG) Kyle Sexton
@ 2009-07-23 22:24 ` Eric S Fraga
  2009-07-23 22:39   ` Richard Riley
  0 siblings, 1 reply; 10+ messages in thread
From: Eric S Fraga @ 2009-07-23 22:24 UTC (permalink / raw)
  To: Kyle Sexton; +Cc: org-mode

At Thu, 23 Jul 2009 14:09:23 -0500,
Kyle Sexton wrote:
> 
> Currently I'm using org-mode with EasyPG and it works great.  Files

Kyle,

can you tell me exactly how you are doing this?  I used to do this
just fine but something broke about 6 months ago and I'm no longer
able to encrypt the file automatically when saving.  That is, it
decrypts just fine and I can edit the file but I get an error when
trying to save it:

,----
| byte-code: Opening output file: integer-or-marker-p, nil
`----

What settings do you have for EasyPG?  All I have are:

,----
| ;; ------------------------------------------ EASYPG
| (require 'epa)
| (epa-file-enable)
| (setq epa-file-cache-passphrase-for-symmetric-encryption t)
`----

I'm using "GNU Emacs 23.0.96.1" on Debian testing with latest org-mode
from git and easypg version 0.0.16-2.

thanks,
eric

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Org-mode and GPG (EasyPG)
  2009-07-23 22:24 ` Eric S Fraga
@ 2009-07-23 22:39   ` Richard Riley
  2009-07-23 22:56     ` Eric S Fraga
  0 siblings, 1 reply; 10+ messages in thread
From: Richard Riley @ 2009-07-23 22:39 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: org-mode

Eric S Fraga <ucecesf@ucl.ac.uk> writes:

> At Thu, 23 Jul 2009 14:09:23 -0500,
> Kyle Sexton wrote:
>> 
>> Currently I'm using org-mode with EasyPG and it works great.  Files
>
> Kyle,
>
> can you tell me exactly how you are doing this?  I used to do this
> just fine but something broke about 6 months ago and I'm no longer
> able to encrypt the file automatically when saving.  That is, it
> decrypts just fine and I can edit the file but I get an error when
> trying to save it:
>
> ,----
> | byte-code: Opening output file: integer-or-marker-p, nil
> `----
>
> What settings do you have for EasyPG?  All I have are:
>
> ,----
> | ;; ------------------------------------------ EASYPG
> | (require 'epa)
> | (epa-file-enable)
> | (setq epa-file-cache-passphrase-for-symmetric-encryption t)
> `----

I have the cache setting above plus

,----
| (setenv "GPG_AGENT_INFO" nil)
`----

Which means emacs prompts you for the pass. I also have the following at
the top of the org (gpg extension)  file fwiw:

,----
| -*- mode: org -*- -*- epa-file-encrypt-to: ("rgr@richardriley.net") -*-
`----

and I dont call epa-file.

Works fine for me with emacs-snapshot on Debian Lenny.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Org-mode and GPG (EasyPG)
  2009-07-23 22:39   ` Richard Riley
@ 2009-07-23 22:56     ` Eric S Fraga
  2009-07-24  9:05       ` Maurice
  0 siblings, 1 reply; 10+ messages in thread
From: Eric S Fraga @ 2009-07-23 22:56 UTC (permalink / raw)
  To: Richard Riley; +Cc: org-mode

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=UTF-8, Size: 1957 bytes --]

At Fri, 24 Jul 2009 00:39:07 +0200, Richard Riley wrote:
> Eric S Fraga <ucecesf@ucl.ac.uk> writes:
> > What settings do you have for EasyPG?  All I have are:
> >
> > ,----
> > | ;; ------------------------------------------ EASYPG
> > | (require 'epa)
> > | (epa-file-enable)
> > | (setq epa-file-cache-passphrase-for-symmetric-encryption t)
> > `----
> 
> I have the cache setting above plus
> 
> ,----
> | (setenv "GPG_AGENT_INFO" nil)
> `----
> 
> Which means emacs prompts you for the pass. I also have the following at
> the top of the org (gpg extension)  file fwiw:
> 
> ,----
> | -*- mode: org -*- -*- epa-file-encrypt-to: ("rgr@richardriley.net") -*-
> `----
> 
> and I dont call epa-file.
> 
> Works fine for me with emacs-snapshot on Debian Lenny.

Very strange.  I did also have the file settings you have (obviously
with my pgp ident, not yours ;-).  I've removed the epa-file-enable
and have included the setenv line you have but I still get the same
error as before.  The backtrace on error doesn't tell me anything
interesting, unfortunately:

,----
| Debugger entered--Lisp error: (file-error "Opening output file" integer-or-marker-p nil)
|   signal(file-error ("Opening output file" integer-or-marker-p nil))
|   byte-code("Ä\b	\"‰\x12ƒ\r\0\nÅ¡ˆÆÇÈ\vAB\"‡" [file epa-file-passphrase-alist entry error assoc nil signal file-error "Opening output file"] 4)
|   epa-file-write-region(nil nil "/home/ucecesf/s/personal/private.org.gpg" nil t)
|   apply(epa-file-write-region (nil nil "/home/ucecesf/s/personal/private.org.gpg" nil t))
|   epa-file-handler(write-region nil nil "/home/ucecesf/s/personal/private.org.gpg" nil t)
|   write-region(nil nil "/home/ucecesf/s/personal/private.org.gpg" nil t "~/synced/personal/private.org.gpg")
|   basic-save-buffer-2()
|   basic-save-buffer-1()
|   basic-save-buffer()
|   save-buffer(1)
|   call-interactively(save-buffer nil nil)
`----

Thanks,
eric

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Org-mode and GPG (EasyPG)
  2009-07-23 22:56     ` Eric S Fraga
@ 2009-07-24  9:05       ` Maurice
  2009-07-24  9:42         ` Eric S Fraga
  0 siblings, 1 reply; 10+ messages in thread
From: Maurice @ 2009-07-24  9:05 UTC (permalink / raw)
  To: emacs-orgmode

Hello org-moders,

Maybe  : http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=503480

Where the maintainer said:

,----
| Removing /usr/share/emacs-snapshot/site-lisp/easypg prevents
| this problem.
| 
| EasyPG is already integrated in the development version of Emacs,
| which will be 23.1 release.  So, please don't install the easypg
| files for the flavors emacs-snapshot and emacs23.
`----

I use easypg without any problem.

Maurice

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Re: Org-mode and GPG (EasyPG)
  2009-07-24  9:05       ` Maurice
@ 2009-07-24  9:42         ` Eric S Fraga
  2009-07-31 14:23           ` Kyle Sexton
  0 siblings, 1 reply; 10+ messages in thread
From: Eric S Fraga @ 2009-07-24  9:42 UTC (permalink / raw)
  To: maurice.boucher; +Cc: emacs-orgmode

At Fri, 24 Jul 2009 11:05:36 +0200,
Maurice wrote:
> 
> Hello org-moders,
> 
> Maybe  : http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=503480

Brilliant!!  Many thanks.  Problem solved.

<blush> 
(now why didn't I think of checking Debian's bug reports???  sigh) 
</blush>

Thanks again,
eric

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Re: Org-mode and GPG (EasyPG)
  2009-07-24  9:42         ` Eric S Fraga
@ 2009-07-31 14:23           ` Kyle Sexton
  2009-08-01 18:43             ` Eric S Fraga, Eric S Fraga
  2009-08-02 10:58             ` Maurice Boucher
  0 siblings, 2 replies; 10+ messages in thread
From: Kyle Sexton @ 2009-07-31 14:23 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: maurice.boucher, emacs-orgmode

At Fri, 24 Jul 2009 10:42:16 +0100,
Eric S Fraga <ucecesf@ucl.ac.uk> wrote:
> 
> At Fri, 24 Jul 2009 11:05:36 +0200,
> Maurice wrote:
> > 
> > Hello org-moders,
> > 
> > Maybe  : http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=503480
> 
> Brilliant!!  Many thanks.  Problem solved.
> 
> <blush> 
> (now why didn't I think of checking Debian's bug reports???  sigh) 
> </blush>
> 
> Thanks again,
> eric
> 
> 

Does this mean you were able to get the agenda view working with
EasyPG as well?   That would be an awesome feature IMHO, pulling tasks
from all my notes, even the encrypted ones.

--
Kyle Sexton

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Re: Org-mode and GPG (EasyPG)
  2009-07-31 14:23           ` Kyle Sexton
@ 2009-08-01 18:43             ` Eric S Fraga, Eric S Fraga
  2009-08-02 10:58             ` Maurice Boucher
  1 sibling, 0 replies; 10+ messages in thread
From: Eric S Fraga, Eric S Fraga @ 2009-08-01 18:43 UTC (permalink / raw)
  To: Kyle Sexton; +Cc: maurice.boucher, emacs-orgmode

At Fri, 31 Jul 2009 09:23:56 -0500,
Kyle Sexton wrote:
> 
> At Fri, 24 Jul 2009 10:42:16 +0100,
> Eric S Fraga <ucecesf@ucl.ac.uk> wrote:
> > 
> > At Fri, 24 Jul 2009 11:05:36 +0200,
> > Maurice wrote:
> > > 
> > > Hello org-moders,
> > > 
> > > Maybe  : http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=503480
> > 
> > Brilliant!!  Many thanks.  Problem solved.
> > 
> > <blush> 
> > (now why didn't I think of checking Debian's bug reports???  sigh) 
> > </blush>
> > 
> > Thanks again,
> > eric
> > 
> > 
> 
> Does this mean you were able to get the agenda view working with
> EasyPG as well?   That would be an awesome feature IMHO, pulling tasks
> from all my notes, even the encrypted ones.
> 
> --
> Kyle Sexton

Kyle,

sorry for any misleading information.  I have not tried incorporating
information from my encrypted org files into an agenda view.  I use
encryption for sensitive notes, none of which comes into "viewable in
the agenda" category for me.  What I managed was to get automatic
decryption and encryption working again thanks to Maurice's pointer.

eric

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Org-mode and GPG (EasyPG)
  2009-07-31 14:23           ` Kyle Sexton
  2009-08-01 18:43             ` Eric S Fraga, Eric S Fraga
@ 2009-08-02 10:58             ` Maurice Boucher
  2009-08-02 11:10               ` Benjamin Andresen
  1 sibling, 1 reply; 10+ messages in thread
From: Maurice Boucher @ 2009-08-02 10:58 UTC (permalink / raw)
  To: emacs-orgmode

Hello,

Kyle Sexton <ks@mocker.org> disait le 31/07/2009 que :

> Does this mean you were able to get the agenda view working with
> EasyPG as well?

In my .emacs, I have :
,----
| (require 'epa)
| (epa-file-enable)
| (setq epa-file-cache-passphrase-for-symmetric-encryption t)   
`----

I run the command : M-x epa-encrypt-file

in mini-buffer, I enter the name of my file : secret_filel.org

In the dialog buffer, 
,----
| Select recipients for encryption.
| If no one is selected, symmetric encryption will be performed.  
| - `m' to mark a key on the line
| - `u' to unmark a key on the line
| [Cancel][OK]
`----

I hit ok for symetric encryption, emacs asks me to type twice my
passphrase.

I get a new file : secret_file.org.gpg, I load it and add it ( C-c [ ) to my
agenda files. 

Next time, if I want to see my agenda view, I have to give my
passphrases that are required for every encrypted files.

I run emacs23 like server in screen (the screen manager) at startup,
this last action (typing passphrases) does not need to be repeated
everytime because I run my agenda views in emacsclients.

Maurice
 

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Org-mode and GPG (EasyPG)
  2009-08-02 10:58             ` Maurice Boucher
@ 2009-08-02 11:10               ` Benjamin Andresen
  0 siblings, 0 replies; 10+ messages in thread
From: Benjamin Andresen @ 2009-08-02 11:10 UTC (permalink / raw)
  To: emacs-orgmode

Hey everyone,

Maurice Boucher <maurice.boucherERASE@wanadoo.fr> writes:

> Hello,
>
> Kyle Sexton <ks@mocker.org> disait le 31/07/2009 que :
>
>> Does this mean you were able to get the agenda view working with
>> EasyPG as well?
>
> In my .emacs, I have :
> ,----
> | (require 'epa)
> | (epa-file-enable)
> | (setq epa-file-cache-passphrase-for-symmetric-encryption t)   
> `----

Not to sound paranoid. But if you want caching, it's recommended to use
public-key encryption instead of symmetric encryption. gpg-agent is the
preferred way to do this. For more information see here:
(info "(pgg) Prerequisites")

Works fine with epa as well.

br,
benny

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2009-08-02 11:10 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-23 19:09 Org-mode and GPG (EasyPG) Kyle Sexton
2009-07-23 22:24 ` Eric S Fraga
2009-07-23 22:39   ` Richard Riley
2009-07-23 22:56     ` Eric S Fraga
2009-07-24  9:05       ` Maurice
2009-07-24  9:42         ` Eric S Fraga
2009-07-31 14:23           ` Kyle Sexton
2009-08-01 18:43             ` Eric S Fraga, Eric S Fraga
2009-08-02 10:58             ` Maurice Boucher
2009-08-02 11:10               ` Benjamin Andresen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.