Hi, Am 01.06.2012 um 14:39 schrieb Nils Kenneweg:
> Signierter PGP Teil > Am 28.05.2012 21:40, schrieb Simon Rothe: > > Hello everyone, > > > > my name is Simon. OpenPGP.js is a great project, that made my life > > a lot easier! Recently, I am working on an extension that encrypts > > messages on facebook. For chrome I got the job done. I am quite > > satisfied with my prototype. Hence it is my task now, to port that > > code to firefox. Getting started with firefox extensions is quite > > hard and I wounder about the best way to include OpenPGP, because > > there are no background pages like in chrome. I guess that someone > > of you might have a similar problem (solved). > > > > If not, my approach is in that direction: > > https://builder.addons.mozilla.org/addon/1054309/latest/ There I > > try to rebuild the contentscript - background page architecture of > > chrome. But I fail to send messages back from the background page. > > I exposed that problem here > > https://builder.addons.mozilla.org/addon/1053549/latest/ Whenever I > > put "self.port.emit("Message2", "This is the background page!");" > > into the function sendResponse() I get an error and the extension > > breaks. > > I do not see the problem. It works fine for me. Firefox will give you > another big problem as window.crypto.getRandomBytes is not available > which is needed by OpenPGP. > You could try to use the random number generator from Stanford Javascript Crypto Library. https://github.com/bitwiseshiftleft/sjcl/blob/master/core/random.js I'm not sure as how reliable it is, but they've published papers on it describing the method the random numbers are generated. > _______________________________________________ > > http://openpgpjs.org Best, Lukas _______________________________________________ http://openpgpjs.org

