├── Gemfile ├── LICENSE.txt ├── README.rst ├── app ├── controllers │ └── pgpkeys_controller.rb ├── helpers │ └── pgpkeys_helper.rb ├── models │ └── pgpkey.rb └── views │ ├── mailer │ ├── attachments_added.filtered.html.erb │ ├── attachments_added.filtered.text.erb │ ├── document_added.filtered.html.erb │ ├── document_added.filtered.text.erb │ ├── issue_add.filtered.html.erb │ ├── issue_add.filtered.text.erb │ ├── issue_edit.filtered.html.erb │ ├── issue_edit.filtered.text.erb │ ├── message_posted.filtered.html.erb │ ├── message_posted.filtered.text.erb │ ├── news_added.filtered.html.erb │ ├── news_added.filtered.text.erb │ ├── news_comment_added.filtered.html.erb │ ├── news_comment_added.filtered.text.erb │ ├── wiki_content_added.filtered.html.erb │ ├── wiki_content_added.filtered.text.erb │ ├── wiki_content_updated.filtered.html.erb │ └── wiki_content_updated.filtered.text.erb │ ├── pgpkeys │ └── index.html.erb │ └── settings │ └── _openpgp.erb ├── config ├── locales │ ├── de.yml │ └── en.yml └── routes.rb ├── db └── migrate │ └── 001_create_pgpkeys.rb ├── init.rb ├── lib ├── decrypt_mails.rb ├── encrypt_mails.rb └── tasks │ ├── generate_redmine_pgpkey.rake │ └── update_redmine_pgpkey.rake └── test ├── functional └── pgpkeys_controller_test.rb ├── pgp.passphrase.private.asc ├── pgp.passphrase.public.asc ├── pgp.server.private.asc ├── pgp.server.public.asc ├── pgp.user.private.asc ├── pgp.user.public.asc ├── test_helper.rb └── unit └── pgpkey_test.rb /Gemfile: -------------------------------------------------------------------------------- 1 | # -*- coding: utf-8 -*- 2 | #gem "gpgme" 3 | gem 'mail-gpg' -------------------------------------------------------------------------------- /LICENSE.txt: -------------------------------------------------------------------------------- 1 | GNU GENERAL PUBLIC LICENSE 2 | Version 3, 29 June 2007 3 | 4 | Copyright (C) 2007 Free Software Foundation, Inc. 5 | Everyone is permitted to copy and distribute verbatim copies 6 | of this license document, but changing it is not allowed. 7 | 8 | Preamble 9 | 10 | The GNU General Public License is a free, copyleft license for 11 | software and other kinds of works. 12 | 13 | The licenses for most software and other practical works are designed 14 | to take away your freedom to share and change the works. By contrast, 15 | the GNU General Public License is intended to guarantee your freedom to 16 | share and change all versions of a program--to make sure it remains free 17 | software for all its users. We, the Free Software Foundation, use the 18 | GNU General Public License for most of our software; it applies also to 19 | any other work released this way by its authors. You can apply it to 20 | your programs, too. 21 | 22 | When we speak of free software, we are referring to freedom, not 23 | price. Our General Public Licenses are designed to make sure that you 24 | have the freedom to distribute copies of free software (and charge for 25 | them if you wish), that you receive source code or can get it if you 26 | want it, that you can change the software or use pieces of it in new 27 | free programs, and that you know you can do these things. 28 | 29 | To protect your rights, we need to prevent others from denying you 30 | these rights or asking you to surrender the rights. Therefore, you have 31 | certain responsibilities if you distribute copies of the software, or if 32 | you modify it: responsibilities to respect the freedom of others. 33 | 34 | For example, if you distribute copies of such a program, whether 35 | gratis or for a fee, you must pass on to the recipients the same 36 | freedoms that you received. You must make sure that they, too, receive 37 | or can get the source code. And you must show them these terms so they 38 | know their rights. 39 | 40 | Developers that use the GNU GPL protect your rights with two steps: 41 | (1) assert copyright on the software, and (2) offer you this License 42 | giving you legal permission to copy, distribute and/or modify it. 43 | 44 | For the developers' and authors' protection, the GPL clearly explains 45 | that there is no warranty for this free software. For both users' and 46 | authors' sake, the GPL requires that modified versions be marked as 47 | changed, so that their problems will not be attributed erroneously to 48 | authors of previous versions. 49 | 50 | Some devices are designed to deny users access to install or run 51 | modified versions of the software inside them, although the manufacturer 52 | can do so. This is fundamentally incompatible with the aim of 53 | protecting users' freedom to change the software. The systematic 54 | pattern of such abuse occurs in the area of products for individuals to 55 | use, which is precisely where it is most unacceptable. Therefore, we 56 | have designed this version of the GPL to prohibit the practice for those 57 | products. If such problems arise substantially in other domains, we 58 | stand ready to extend this provision to those domains in future versions 59 | of the GPL, as needed to protect the freedom of users. 60 | 61 | Finally, every program is threatened constantly by software patents. 62 | States should not allow patents to restrict development and use of 63 | software on general-purpose computers, but in those that do, we wish to 64 | avoid the special danger that patents applied to a free program could 65 | make it effectively proprietary. To prevent this, the GPL assures that 66 | patents cannot be used to render the program non-free. 67 | 68 | The precise terms and conditions for copying, distribution and 69 | modification follow. 70 | 71 | TERMS AND CONDITIONS 72 | 73 | 0. Definitions. 74 | 75 | "This License" refers to version 3 of the GNU General Public License. 76 | 77 | "Copyright" also means copyright-like laws that apply to other kinds of 78 | works, such as semiconductor masks. 79 | 80 | "The Program" refers to any copyrightable work licensed under this 81 | License. Each licensee is addressed as "you". "Licensees" and 82 | "recipients" may be individuals or organizations. 83 | 84 | To "modify" a work means to copy from or adapt all or part of the work 85 | in a fashion requiring copyright permission, other than the making of an 86 | exact copy. The resulting work is called a "modified version" of the 87 | earlier work or a work "based on" the earlier work. 88 | 89 | A "covered work" means either the unmodified Program or a work based 90 | on the Program. 91 | 92 | To "propagate" a work means to do anything with it that, without 93 | permission, would make you directly or secondarily liable for 94 | infringement under applicable copyright law, except executing it on a 95 | computer or modifying a private copy. Propagation includes copying, 96 | distribution (with or without modification), making available to the 97 | public, and in some countries other activities as well. 98 | 99 | To "convey" a work means any kind of propagation that enables other 100 | parties to make or receive copies. Mere interaction with a user through 101 | a computer network, with no transfer of a copy, is not conveying. 102 | 103 | An interactive user interface displays "Appropriate Legal Notices" 104 | to the extent that it includes a convenient and prominently visible 105 | feature that (1) displays an appropriate copyright notice, and (2) 106 | tells the user that there is no warranty for the work (except to the 107 | extent that warranties are provided), that licensees may convey the 108 | work under this License, and how to view a copy of this License. If 109 | the interface presents a list of user commands or options, such as a 110 | menu, a prominent item in the list meets this criterion. 111 | 112 | 1. Source Code. 113 | 114 | The "source code" for a work means the preferred form of the work 115 | for making modifications to it. "Object code" means any non-source 116 | form of a work. 117 | 118 | A "Standard Interface" means an interface that either is an official 119 | standard defined by a recognized standards body, or, in the case of 120 | interfaces specified for a particular programming language, one that 121 | is widely used among developers working in that language. 122 | 123 | The "System Libraries" of an executable work include anything, other 124 | than the work as a whole, that (a) is included in the normal form of 125 | packaging a Major Component, but which is not part of that Major 126 | Component, and (b) serves only to enable use of the work with that 127 | Major Component, or to implement a Standard Interface for which an 128 | implementation is available to the public in source code form. A 129 | "Major Component", in this context, means a major essential component 130 | (kernel, window system, and so on) of the specific operating system 131 | (if any) on which the executable work runs, or a compiler used to 132 | produce the work, or an object code interpreter used to run it. 133 | 134 | The "Corresponding Source" for a work in object code form means all 135 | the source code needed to generate, install, and (for an executable 136 | work) run the object code and to modify the work, including scripts to 137 | control those activities. However, it does not include the work's 138 | System Libraries, or general-purpose tools or generally available free 139 | programs which are used unmodified in performing those activities but 140 | which are not part of the work. For example, Corresponding Source 141 | includes interface definition files associated with source files for 142 | the work, and the source code for shared libraries and dynamically 143 | linked subprograms that the work is specifically designed to require, 144 | such as by intimate data communication or control flow between those 145 | subprograms and other parts of the work. 146 | 147 | The Corresponding Source need not include anything that users 148 | can regenerate automatically from other parts of the Corresponding 149 | Source. 150 | 151 | The Corresponding Source for a work in source code form is that 152 | same work. 153 | 154 | 2. Basic Permissions. 155 | 156 | All rights granted under this License are granted for the term of 157 | copyright on the Program, and are irrevocable provided the stated 158 | conditions are met. This License explicitly affirms your unlimited 159 | permission to run the unmodified Program. The output from running a 160 | covered work is covered by this License only if the output, given its 161 | content, constitutes a covered work. This License acknowledges your 162 | rights of fair use or other equivalent, as provided by copyright law. 163 | 164 | You may make, run and propagate covered works that you do not 165 | convey, without conditions so long as your license otherwise remains 166 | in force. You may convey covered works to others for the sole purpose 167 | of having them make modifications exclusively for you, or provide you 168 | with facilities for running those works, provided that you comply with 169 | the terms of this License in conveying all material for which you do 170 | not control copyright. Those thus making or running the covered works 171 | for you must do so exclusively on your behalf, under your direction 172 | and control, on terms that prohibit them from making any copies of 173 | your copyrighted material outside their relationship with you. 174 | 175 | Conveying under any other circumstances is permitted solely under 176 | the conditions stated below. Sublicensing is not allowed; section 10 177 | makes it unnecessary. 178 | 179 | 3. Protecting Users' Legal Rights From Anti-Circumvention Law. 180 | 181 | No covered work shall be deemed part of an effective technological 182 | measure under any applicable law fulfilling obligations under article 183 | 11 of the WIPO copyright treaty adopted on 20 December 1996, or 184 | similar laws prohibiting or restricting circumvention of such 185 | measures. 186 | 187 | When you convey a covered work, you waive any legal power to forbid 188 | circumvention of technological measures to the extent such circumvention 189 | is effected by exercising rights under this License with respect to 190 | the covered work, and you disclaim any intention to limit operation or 191 | modification of the work as a means of enforcing, against the work's 192 | users, your or third parties' legal rights to forbid circumvention of 193 | technological measures. 194 | 195 | 4. Conveying Verbatim Copies. 196 | 197 | You may convey verbatim copies of the Program's source code as you 198 | receive it, in any medium, provided that you conspicuously and 199 | appropriately publish on each copy an appropriate copyright notice; 200 | keep intact all notices stating that this License and any 201 | non-permissive terms added in accord with section 7 apply to the code; 202 | keep intact all notices of the absence of any warranty; and give all 203 | recipients a copy of this License along with the Program. 204 | 205 | You may charge any price or no price for each copy that you convey, 206 | and you may offer support or warranty protection for a fee. 207 | 208 | 5. Conveying Modified Source Versions. 209 | 210 | You may convey a work based on the Program, or the modifications to 211 | produce it from the Program, in the form of source code under the 212 | terms of section 4, provided that you also meet all of these conditions: 213 | 214 | a) The work must carry prominent notices stating that you modified 215 | it, and giving a relevant date. 216 | 217 | b) The work must carry prominent notices stating that it is 218 | released under this License and any conditions added under section 219 | 7. This requirement modifies the requirement in section 4 to 220 | "keep intact all notices". 221 | 222 | c) You must license the entire work, as a whole, under this 223 | License to anyone who comes into possession of a copy. This 224 | License will therefore apply, along with any applicable section 7 225 | additional terms, to the whole of the work, and all its parts, 226 | regardless of how they are packaged. This License gives no 227 | permission to license the work in any other way, but it does not 228 | invalidate such permission if you have separately received it. 229 | 230 | d) If the work has interactive user interfaces, each must display 231 | Appropriate Legal Notices; however, if the Program has interactive 232 | interfaces that do not display Appropriate Legal Notices, your 233 | work need not make them do so. 234 | 235 | A compilation of a covered work with other separate and independent 236 | works, which are not by their nature extensions of the covered work, 237 | and which are not combined with it such as to form a larger program, 238 | in or on a volume of a storage or distribution medium, is called an 239 | "aggregate" if the compilation and its resulting copyright are not 240 | used to limit the access or legal rights of the compilation's users 241 | beyond what the individual works permit. Inclusion of a covered work 242 | in an aggregate does not cause this License to apply to the other 243 | parts of the aggregate. 244 | 245 | 6. Conveying Non-Source Forms. 246 | 247 | You may convey a covered work in object code form under the terms 248 | of sections 4 and 5, provided that you also convey the 249 | machine-readable Corresponding Source under the terms of this License, 250 | in one of these ways: 251 | 252 | a) Convey the object code in, or embodied in, a physical product 253 | (including a physical distribution medium), accompanied by the 254 | Corresponding Source fixed on a durable physical medium 255 | customarily used for software interchange. 256 | 257 | b) Convey the object code in, or embodied in, a physical product 258 | (including a physical distribution medium), accompanied by a 259 | written offer, valid for at least three years and valid for as 260 | long as you offer spare parts or customer support for that product 261 | model, to give anyone who possesses the object code either (1) a 262 | copy of the Corresponding Source for all the software in the 263 | product that is covered by this License, on a durable physical 264 | medium customarily used for software interchange, for a price no 265 | more than your reasonable cost of physically performing this 266 | conveying of source, or (2) access to copy the 267 | Corresponding Source from a network server at no charge. 268 | 269 | c) Convey individual copies of the object code with a copy of the 270 | written offer to provide the Corresponding Source. This 271 | alternative is allowed only occasionally and noncommercially, and 272 | only if you received the object code with such an offer, in accord 273 | with subsection 6b. 274 | 275 | d) Convey the object code by offering access from a designated 276 | place (gratis or for a charge), and offer equivalent access to the 277 | Corresponding Source in the same way through the same place at no 278 | further charge. You need not require recipients to copy the 279 | Corresponding Source along with the object code. If the place to 280 | copy the object code is a network server, the Corresponding Source 281 | may be on a different server (operated by you or a third party) 282 | that supports equivalent copying facilities, provided you maintain 283 | clear directions next to the object code saying where to find the 284 | Corresponding Source. Regardless of what server hosts the 285 | Corresponding Source, you remain obligated to ensure that it is 286 | available for as long as needed to satisfy these requirements. 287 | 288 | e) Convey the object code using peer-to-peer transmission, provided 289 | you inform other peers where the object code and Corresponding 290 | Source of the work are being offered to the general public at no 291 | charge under subsection 6d. 292 | 293 | A separable portion of the object code, whose source code is excluded 294 | from the Corresponding Source as a System Library, need not be 295 | included in conveying the object code work. 296 | 297 | A "User Product" is either (1) a "consumer product", which means any 298 | tangible personal property which is normally used for personal, family, 299 | or household purposes, or (2) anything designed or sold for incorporation 300 | into a dwelling. In determining whether a product is a consumer product, 301 | doubtful cases shall be resolved in favor of coverage. For a particular 302 | product received by a particular user, "normally used" refers to a 303 | typical or common use of that class of product, regardless of the status 304 | of the particular user or of the way in which the particular user 305 | actually uses, or expects or is expected to use, the product. A product 306 | is a consumer product regardless of whether the product has substantial 307 | commercial, industrial or non-consumer uses, unless such uses represent 308 | the only significant mode of use of the product. 309 | 310 | "Installation Information" for a User Product means any methods, 311 | procedures, authorization keys, or other information required to install 312 | and execute modified versions of a covered work in that User Product from 313 | a modified version of its Corresponding Source. The information must 314 | suffice to ensure that the continued functioning of the modified object 315 | code is in no case prevented or interfered with solely because 316 | modification has been made. 317 | 318 | If you convey an object code work under this section in, or with, or 319 | specifically for use in, a User Product, and the conveying occurs as 320 | part of a transaction in which the right of possession and use of the 321 | User Product is transferred to the recipient in perpetuity or for a 322 | fixed term (regardless of how the transaction is characterized), the 323 | Corresponding Source conveyed under this section must be accompanied 324 | by the Installation Information. But this requirement does not apply 325 | if neither you nor any third party retains the ability to install 326 | modified object code on the User Product (for example, the work has 327 | been installed in ROM). 328 | 329 | The requirement to provide Installation Information does not include a 330 | requirement to continue to provide support service, warranty, or updates 331 | for a work that has been modified or installed by the recipient, or for 332 | the User Product in which it has been modified or installed. Access to a 333 | network may be denied when the modification itself materially and 334 | adversely affects the operation of the network or violates the rules and 335 | protocols for communication across the network. 336 | 337 | Corresponding Source conveyed, and Installation Information provided, 338 | in accord with this section must be in a format that is publicly 339 | documented (and with an implementation available to the public in 340 | source code form), and must require no special password or key for 341 | unpacking, reading or copying. 342 | 343 | 7. Additional Terms. 344 | 345 | "Additional permissions" are terms that supplement the terms of this 346 | License by making exceptions from one or more of its conditions. 347 | Additional permissions that are applicable to the entire Program shall 348 | be treated as though they were included in this License, to the extent 349 | that they are valid under applicable law. If additional permissions 350 | apply only to part of the Program, that part may be used separately 351 | under those permissions, but the entire Program remains governed by 352 | this License without regard to the additional permissions. 353 | 354 | When you convey a copy of a covered work, you may at your option 355 | remove any additional permissions from that copy, or from any part of 356 | it. (Additional permissions may be written to require their own 357 | removal in certain cases when you modify the work.) You may place 358 | additional permissions on material, added by you to a covered work, 359 | for which you have or can give appropriate copyright permission. 360 | 361 | Notwithstanding any other provision of this License, for material you 362 | add to a covered work, you may (if authorized by the copyright holders of 363 | that material) supplement the terms of this License with terms: 364 | 365 | a) Disclaiming warranty or limiting liability differently from the 366 | terms of sections 15 and 16 of this License; or 367 | 368 | b) Requiring preservation of specified reasonable legal notices or 369 | author attributions in that material or in the Appropriate Legal 370 | Notices displayed by works containing it; or 371 | 372 | c) Prohibiting misrepresentation of the origin of that material, or 373 | requiring that modified versions of such material be marked in 374 | reasonable ways as different from the original version; or 375 | 376 | d) Limiting the use for publicity purposes of names of licensors or 377 | authors of the material; or 378 | 379 | e) Declining to grant rights under trademark law for use of some 380 | trade names, trademarks, or service marks; or 381 | 382 | f) Requiring indemnification of licensors and authors of that 383 | material by anyone who conveys the material (or modified versions of 384 | it) with contractual assumptions of liability to the recipient, for 385 | any liability that these contractual assumptions directly impose on 386 | those licensors and authors. 387 | 388 | All other non-permissive additional terms are considered "further 389 | restrictions" within the meaning of section 10. If the Program as you 390 | received it, or any part of it, contains a notice stating that it is 391 | governed by this License along with a term that is a further 392 | restriction, you may remove that term. If a license document contains 393 | a further restriction but permits relicensing or conveying under this 394 | License, you may add to a covered work material governed by the terms 395 | of that license document, provided that the further restriction does 396 | not survive such relicensing or conveying. 397 | 398 | If you add terms to a covered work in accord with this section, you 399 | must place, in the relevant source files, a statement of the 400 | additional terms that apply to those files, or a notice indicating 401 | where to find the applicable terms. 402 | 403 | Additional terms, permissive or non-permissive, may be stated in the 404 | form of a separately written license, or stated as exceptions; 405 | the above requirements apply either way. 406 | 407 | 8. Termination. 408 | 409 | You may not propagate or modify a covered work except as expressly 410 | provided under this License. Any attempt otherwise to propagate or 411 | modify it is void, and will automatically terminate your rights under 412 | this License (including any patent licenses granted under the third 413 | paragraph of section 11). 414 | 415 | However, if you cease all violation of this License, then your 416 | license from a particular copyright holder is reinstated (a) 417 | provisionally, unless and until the copyright holder explicitly and 418 | finally terminates your license, and (b) permanently, if the copyright 419 | holder fails to notify you of the violation by some reasonable means 420 | prior to 60 days after the cessation. 421 | 422 | Moreover, your license from a particular copyright holder is 423 | reinstated permanently if the copyright holder notifies you of the 424 | violation by some reasonable means, this is the first time you have 425 | received notice of violation of this License (for any work) from that 426 | copyright holder, and you cure the violation prior to 30 days after 427 | your receipt of the notice. 428 | 429 | Termination of your rights under this section does not terminate the 430 | licenses of parties who have received copies or rights from you under 431 | this License. If your rights have been terminated and not permanently 432 | reinstated, you do not qualify to receive new licenses for the same 433 | material under section 10. 434 | 435 | 9. Acceptance Not Required for Having Copies. 436 | 437 | You are not required to accept this License in order to receive or 438 | run a copy of the Program. Ancillary propagation of a covered work 439 | occurring solely as a consequence of using peer-to-peer transmission 440 | to receive a copy likewise does not require acceptance. However, 441 | nothing other than this License grants you permission to propagate or 442 | modify any covered work. These actions infringe copyright if you do 443 | not accept this License. Therefore, by modifying or propagating a 444 | covered work, you indicate your acceptance of this License to do so. 445 | 446 | 10. Automatic Licensing of Downstream Recipients. 447 | 448 | Each time you convey a covered work, the recipient automatically 449 | receives a license from the original licensors, to run, modify and 450 | propagate that work, subject to this License. You are not responsible 451 | for enforcing compliance by third parties with this License. 452 | 453 | An "entity transaction" is a transaction transferring control of an 454 | organization, or substantially all assets of one, or subdividing an 455 | organization, or merging organizations. If propagation of a covered 456 | work results from an entity transaction, each party to that 457 | transaction who receives a copy of the work also receives whatever 458 | licenses to the work the party's predecessor in interest had or could 459 | give under the previous paragraph, plus a right to possession of the 460 | Corresponding Source of the work from the predecessor in interest, if 461 | the predecessor has it or can get it with reasonable efforts. 462 | 463 | You may not impose any further restrictions on the exercise of the 464 | rights granted or affirmed under this License. For example, you may 465 | not impose a license fee, royalty, or other charge for exercise of 466 | rights granted under this License, and you may not initiate litigation 467 | (including a cross-claim or counterclaim in a lawsuit) alleging that 468 | any patent claim is infringed by making, using, selling, offering for 469 | sale, or importing the Program or any portion of it. 470 | 471 | 11. Patents. 472 | 473 | A "contributor" is a copyright holder who authorizes use under this 474 | License of the Program or a work on which the Program is based. The 475 | work thus licensed is called the contributor's "contributor version". 476 | 477 | A contributor's "essential patent claims" are all patent claims 478 | owned or controlled by the contributor, whether already acquired or 479 | hereafter acquired, that would be infringed by some manner, permitted 480 | by this License, of making, using, or selling its contributor version, 481 | but do not include claims that would be infringed only as a 482 | consequence of further modification of the contributor version. For 483 | purposes of this definition, "control" includes the right to grant 484 | patent sublicenses in a manner consistent with the requirements of 485 | this License. 486 | 487 | Each contributor grants you a non-exclusive, worldwide, royalty-free 488 | patent license under the contributor's essential patent claims, to 489 | make, use, sell, offer for sale, import and otherwise run, modify and 490 | propagate the contents of its contributor version. 491 | 492 | In the following three paragraphs, a "patent license" is any express 493 | agreement or commitment, however denominated, not to enforce a patent 494 | (such as an express permission to practice a patent or covenant not to 495 | sue for patent infringement). To "grant" such a patent license to a 496 | party means to make such an agreement or commitment not to enforce a 497 | patent against the party. 498 | 499 | If you convey a covered work, knowingly relying on a patent license, 500 | and the Corresponding Source of the work is not available for anyone 501 | to copy, free of charge and under the terms of this License, through a 502 | publicly available network server or other readily accessible means, 503 | then you must either (1) cause the Corresponding Source to be so 504 | available, or (2) arrange to deprive yourself of the benefit of the 505 | patent license for this particular work, or (3) arrange, in a manner 506 | consistent with the requirements of this License, to extend the patent 507 | license to downstream recipients. "Knowingly relying" means you have 508 | actual knowledge that, but for the patent license, your conveying the 509 | covered work in a country, or your recipient's use of the covered work 510 | in a country, would infringe one or more identifiable patents in that 511 | country that you have reason to believe are valid. 512 | 513 | If, pursuant to or in connection with a single transaction or 514 | arrangement, you convey, or propagate by procuring conveyance of, a 515 | covered work, and grant a patent license to some of the parties 516 | receiving the covered work authorizing them to use, propagate, modify 517 | or convey a specific copy of the covered work, then the patent license 518 | you grant is automatically extended to all recipients of the covered 519 | work and works based on it. 520 | 521 | A patent license is "discriminatory" if it does not include within 522 | the scope of its coverage, prohibits the exercise of, or is 523 | conditioned on the non-exercise of one or more of the rights that are 524 | specifically granted under this License. You may not convey a covered 525 | work if you are a party to an arrangement with a third party that is 526 | in the business of distributing software, under which you make payment 527 | to the third party based on the extent of your activity of conveying 528 | the work, and under which the third party grants, to any of the 529 | parties who would receive the covered work from you, a discriminatory 530 | patent license (a) in connection with copies of the covered work 531 | conveyed by you (or copies made from those copies), or (b) primarily 532 | for and in connection with specific products or compilations that 533 | contain the covered work, unless you entered into that arrangement, 534 | or that patent license was granted, prior to 28 March 2007. 535 | 536 | Nothing in this License shall be construed as excluding or limiting 537 | any implied license or other defenses to infringement that may 538 | otherwise be available to you under applicable patent law. 539 | 540 | 12. No Surrender of Others' Freedom. 541 | 542 | If conditions are imposed on you (whether by court order, agreement or 543 | otherwise) that contradict the conditions of this License, they do not 544 | excuse you from the conditions of this License. If you cannot convey a 545 | covered work so as to satisfy simultaneously your obligations under this 546 | License and any other pertinent obligations, then as a consequence you may 547 | not convey it at all. For example, if you agree to terms that obligate you 548 | to collect a royalty for further conveying from those to whom you convey 549 | the Program, the only way you could satisfy both those terms and this 550 | License would be to refrain entirely from conveying the Program. 551 | 552 | 13. Use with the GNU Affero General Public License. 553 | 554 | Notwithstanding any other provision of this License, you have 555 | permission to link or combine any covered work with a work licensed 556 | under version 3 of the GNU Affero General Public License into a single 557 | combined work, and to convey the resulting work. The terms of this 558 | License will continue to apply to the part which is the covered work, 559 | but the special requirements of the GNU Affero General Public License, 560 | section 13, concerning interaction through a network will apply to the 561 | combination as such. 562 | 563 | 14. Revised Versions of this License. 564 | 565 | The Free Software Foundation may publish revised and/or new versions of 566 | the GNU General Public License from time to time. Such new versions will 567 | be similar in spirit to the present version, but may differ in detail to 568 | address new problems or concerns. 569 | 570 | Each version is given a distinguishing version number. If the 571 | Program specifies that a certain numbered version of the GNU General 572 | Public License "or any later version" applies to it, you have the 573 | option of following the terms and conditions either of that numbered 574 | version or of any later version published by the Free Software 575 | Foundation. If the Program does not specify a version number of the 576 | GNU General Public License, you may choose any version ever published 577 | by the Free Software Foundation. 578 | 579 | If the Program specifies that a proxy can decide which future 580 | versions of the GNU General Public License can be used, that proxy's 581 | public statement of acceptance of a version permanently authorizes you 582 | to choose that version for the Program. 583 | 584 | Later license versions may give you additional or different 585 | permissions. However, no additional obligations are imposed on any 586 | author or copyright holder as a result of your choosing to follow a 587 | later version. 588 | 589 | 15. Disclaimer of Warranty. 590 | 591 | THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY 592 | APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT 593 | HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY 594 | OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, 595 | THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 596 | PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM 597 | IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF 598 | ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 599 | 600 | 16. Limitation of Liability. 601 | 602 | IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 603 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS 604 | THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY 605 | GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE 606 | USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF 607 | DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD 608 | PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), 609 | EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF 610 | SUCH DAMAGES. 611 | 612 | 17. Interpretation of Sections 15 and 16. 613 | 614 | If the disclaimer of warranty and limitation of liability provided 615 | above cannot be given local legal effect according to their terms, 616 | reviewing courts shall apply local law that most closely approximates 617 | an absolute waiver of all civil liability in connection with the 618 | Program, unless a warranty or assumption of liability accompanies a 619 | copy of the Program in return for a fee. 620 | 621 | END OF TERMS AND CONDITIONS 622 | 623 | How to Apply These Terms to Your New Programs 624 | 625 | If you develop a new program, and you want it to be of the greatest 626 | possible use to the public, the best way to achieve this is to make it 627 | free software which everyone can redistribute and change under these terms. 628 | 629 | To do so, attach the following notices to the program. It is safest 630 | to attach them to the start of each source file to most effectively 631 | state the exclusion of warranty; and each file should have at least 632 | the "copyright" line and a pointer to where the full notice is found. 633 | 634 | 635 | Copyright (C) 636 | 637 | This program is free software: you can redistribute it and/or modify 638 | it under the terms of the GNU General Public License as published by 639 | the Free Software Foundation, either version 3 of the License, or 640 | (at your option) any later version. 641 | 642 | This program is distributed in the hope that it will be useful, 643 | but WITHOUT ANY WARRANTY; without even the implied warranty of 644 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 645 | GNU General Public License for more details. 646 | 647 | You should have received a copy of the GNU General Public License 648 | along with this program. If not, see . 649 | 650 | Also add information on how to contact you by electronic and paper mail. 651 | 652 | If the program does terminal interaction, make it output a short 653 | notice like this when it starts in an interactive mode: 654 | 655 | Copyright (C) 656 | This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. 657 | This is free software, and you are welcome to redistribute it 658 | under certain conditions; type `show c' for details. 659 | 660 | The hypothetical commands `show w' and `show c' should show the appropriate 661 | parts of the General Public License. Of course, your program's commands 662 | might be different; for a GUI interface, you would use an "about box". 663 | 664 | You should also get your employer (if you work as a programmer) or school, 665 | if any, to sign a "copyright disclaimer" for the program, if necessary. 666 | For more information on this, and how to apply and follow the GNU GPL, see 667 | . 668 | 669 | The GNU General Public License does not permit incorporating your program 670 | into proprietary programs. If your program is a subroutine library, you 671 | may consider it more useful to permit linking proprietary applications with 672 | the library. If this is what you want to do, use the GNU Lesser General 673 | Public License instead of this License. But first, please read 674 | . 675 | -------------------------------------------------------------------------------- /README.rst: -------------------------------------------------------------------------------- 1 | =============== 2 | Redmine OpenPGP 3 | =============== 4 | 5 | A plugin for Redmine to enhance the security of email communication by 6 | 7 | - de-/encrypting in-/outgoing emails with the OpenPGP standard 8 | - filtering content of unencrypted emails 9 | 10 | developed for `C3S - (Cultural Commons Collecting Society) `_ 11 | 12 | 13 | Details 14 | ======= 15 | 16 | Users may 17 | 18 | - *add* / *remove* their public PGP key 19 | - *see* the public PGP key of the redmine server 20 | 21 | Administrators may 22 | 23 | - choose to *pass* / *reject* incoming mails without a valid signature for all projects 24 | - activate outgoing mail handling for *all* / *selected* / *no* projects 25 | - *add* / *generate* / *remove* a private PGP key for the redmine server (both *server-side* / *client-side*) 26 | - choose to *pass* / *filter* / *block* outgoing unencrypted mails 27 | - add a *footer message* to filtered mails 28 | 29 | Encrypted mails may be 30 | 31 | - *PGP/MIME* or *PGP/Inline* (incoming) 32 | - *PGP/MIME* (outgoing) 33 | 34 | Unencrypted mails may be 35 | 36 | - *blocked*: no mail is sent 37 | - *filtered*: body is reduced to the link to the added / updated object and an invitation to add the public PGP key; headers & subject are unchanged 38 | - *unchanged*: mail is sent unchanged 39 | 40 | Notifications affected: 41 | 42 | - attachments_added 43 | - document_added 44 | - issue_add 45 | - issue_edit 46 | - message_posted 47 | - news_added 48 | - news_comment_added 49 | - wiki_content_added 50 | - wiki_content_updated 51 | 52 | 53 | Dependencies 54 | ============ 55 | 56 | - gpg (http://www.gnupg.org/download/) 57 | - gpgme (https://github.com/ueno/ruby-gpgme) 58 | - mail-gpg (https://github.com/jkraemer/mail-gpg) 59 | 60 | 61 | Compatibility 62 | ============= 63 | 64 | This plugin has been tested with 65 | :: 66 | 67 | gnupg 1.4.18 68 | ruby 2.1.5p273 69 | rails 4.2.3 70 | redmine 3.1.0 71 | gpgme 2.0.9 72 | mail-gpg 0.2.4 73 | 74 | *Note:* ``gpg`` == 2.0.X will not work (see `here `_). ``gpg`` >= 2.1 will probably work, if a gpgme passphrase callback function is added to the code (but is still missing). Downgrade to 1.X or install 1.X parallel and symlink ``/usr/bin/gpg`` to ``/usr/bin/gpg2`` 75 | 76 | 77 | Installation 78 | ============ 79 | 80 | #. Change into plugin directory 81 | 82 | ``$cd /path/to/redmine/plugins`` 83 | 84 | #. Clone this repo into ``/path/to/redmine/plugins/openpgp`` 85 | 86 | ``$git clone https://github.com/C3S/redmine_openpgp openpgp`` 87 | 88 | #. Import the public PGP key for signature verification 89 | 90 | ``$git show pgp | gpg --import`` 91 | 92 | #. Verify the signature 93 | 94 | ``$git tag --verify 1.0`` 95 | 96 | #. Change to current release tag 97 | 98 | ``$git checkout tags/1.0`` 99 | 100 | #. Change into redmine root directory 101 | 102 | ``$cd /path/to/redmine`` 103 | 104 | #. Install gems 105 | 106 | ``$bundle install`` 107 | 108 | #. Migrate database 109 | 110 | ``$RAILS_ENV=production bundle exec rake redmine:plugins:migrate`` 111 | 112 | #. Restart redmine 113 | 114 | ``$sudo service apache2 restart`` 115 | 116 | 117 | Configuration 118 | ============= 119 | 120 | Administrators 121 | -------------- 122 | 123 | #. Configure redmine 124 | 125 | - *Administration / Settings / Email notifications* 126 | 127 | - Emission email address 128 | 129 | - *Administration / Settings / General* 130 | 131 | - Host name and path 132 | - Protocol 133 | 134 | - *Administration / Settings / Incoming emails* 135 | 136 | - Enable WS for incoming emails 137 | - API key 138 | - Exclude attachments by name: ``*.asc, *.pgp, *.gpg`` 139 | 140 | #. Configure plugin 141 | 142 | - *Administration / Plugins / Openpgp* 143 | 144 | #. Add or generate a private PGP key for the redmine server 145 | 146 | - *either* server-side (secure) 147 | - *or* client-side (**INSECURE over http**, more or less secure over https) 148 | 149 | *Note:* The remote server needs enough entropy to generate random, secure keys. If the server side generation process does not proceed or the client side connection has a timeout, connect to the remote server and try ``ls -R /`` several times. If you use ``rngd`` for entropy generation, be advised not to use ``/dev/urandom`` as source for important keys. 150 | 151 | Adding an existing private PGP key server-side 152 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 153 | 154 | #. Export the private PGP key (ascii armored) and save it into a file on the server 155 | 156 | #. Change into redmine root directory 157 | 158 | ``$cd /path/to/redmine`` 159 | 160 | #. Use a rake task to add the existing key, deleting the old one. Point ``keyfile`` to the absolute path to the key file and choose a ``secret``: 161 | 162 | ``$RAILS_ENV="production" bundle exec rake redmine:update_redmine_pgpkey keyfile="/path/to/key.asc" secret="passphrase"`` 163 | 164 | Generating a new private PGP key server-side 165 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 166 | 167 | #. Change into redmine root directory 168 | 169 | ``$cd /path/to/redmine`` 170 | 171 | #. Use a rake task to generate the new key, deleting the old one. Choose a ``secret``: 172 | 173 | ``$RAILS_ENV="production" bundle exec rake redmine:generate_redmine_pgpkey secret="passphrase"`` 174 | 175 | Managing a private PGP keys client-side 176 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 177 | 178 | #. Log into redmine as administrator 179 | 180 | #. Visit http://REDMINE.URL/pgp (or follow the new "PGP" link in the account menue) 181 | 182 | #. Follow the instructions (on the right side) 183 | 184 | Users 185 | ----- 186 | 187 | #. Log into redmine 188 | 189 | #. Visit http://REDMINE.URL/pgp (or follow the new "PGP" link in the account menue) 190 | 191 | #. Add your public PGP key 192 | 193 | #. Copy & paste the public PGP key for the redmine server into a local file on your machine 194 | 195 | #. Import this file into your local gpg key ring 196 | 197 | *Note:* The private PGP key for the redmine server has to be added by an administrator, before the corresponding public PGP key is displayed. 198 | 199 | 200 | Uninstallation 201 | ============== 202 | 203 | #. Change into redmine root directory 204 | 205 | ``$cd /path/to/redmine`` 206 | 207 | #. Downgrade the database 208 | 209 | ``$RAILS_ENV=production rake redmine:plugins:migrate NAME=openpgp VERSION=0`` 210 | 211 | #. Remove the files 212 | 213 | ``$rm -r /path/to/redmine/plugins/openpgp`` 214 | 215 | 216 | Implementation 217 | ============== 218 | 219 | The table ``pgpkeys`` is added to the redmine database: 220 | 221 | - each entry associates a redmine user (``user_id``) with the unique fingerprint of a key (``fpr``). This allows for matching fingerprints instead of email address, thus enabling redmine users to delete/update their keys and use keys, which don't match their email address 222 | - the entry with ``user_id`` 0 is reserved for the private key of the redmine server additionally containing the secret passphrase (``secret``) 223 | 224 | The following gems are used: 225 | 226 | - ``mail-gpg`` for de-/encryption and signature handling within ``Mail`` / ``ActionMailer`` 227 | - ``gpgme`` to interact with ``gpg`` running on the server 228 | 229 | Whenever a key is added: 230 | 231 | - the key is imported into the ``gpg`` key ring of the system user owning the redmine process 232 | - an entry is added to the table ``pgpkeys`` 233 | 234 | Whenever a key is removed: 235 | 236 | - the corresponding entry in the table ``pgpkeys`` is deleted 237 | - if there are no other references to this key within the table ``pgpkeys``: 238 | 239 | - the key is **removed from the gpg key ring** as well 240 | 241 | Whenever a mail is sent: 242 | 243 | - if the plugin is enabled globally or on project level: 244 | 245 | - if the recipient owns a key: 246 | 247 | - the mail is encryted for the recipient 248 | - if the redmine server owns a key: 249 | 250 | - the mail is signed by the redmine user 251 | 252 | - else: the mail is blocked / filtered / passed unchanged, depending on the plugin settings 253 | 254 | Whenever a mail is recieved: 255 | 256 | - it will be decrypted if encrypted 257 | 258 | - depending on the plugin settings it will be rejected if the signature is invalid 259 | 260 | 261 | Improvements 262 | ============ 263 | 264 | - Add tests 265 | - Add languages 266 | - Add LDAP integration for importing keys 267 | - Add gpgme passphrase callback for ``gpg`` >= 2.1, retaining compatibility to ``gpg`` < 2 268 | 269 | 270 | Links 271 | ===== 272 | 273 | - `GPG `_ (reference) 274 | - `ActionMailer `_ (reference) 275 | - `mail `_ (reference) 276 | - `gpgme `_ (reference) 277 | - `mail-gpg `_ (reference) 278 | - `PGP/MIME `_ (RFC) 279 | - `PGP Formats `_ (explanation) 280 | 281 | 282 | Contributions 283 | ============= 284 | 285 | - `Alexander Blum `_ 286 | 287 | 288 | License 289 | ======= 290 | :: 291 | 292 | Redmine plugin for email encryption with the OpenPGP standard 293 | Copyright (C) 2015 Alexander Blum 294 | 295 | This program is free software: you can redistribute it and/or modify 296 | it under the terms of the GNU General Public License as published by 297 | the Free Software Foundation, either version 3 of the License, or 298 | (at your option) any later version. 299 | 300 | This program is distributed in the hope that it will be useful, 301 | but WITHOUT ANY WARRANTY; without even the implied warranty of 302 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 303 | GNU General Public License for more details. 304 | 305 | You should have received a copy of the GNU General Public License 306 | along with this program. If not, see . 307 | -------------------------------------------------------------------------------- /app/controllers/pgpkeys_controller.rb: -------------------------------------------------------------------------------- 1 | class PgpkeysController < ApplicationController 2 | unloadable 3 | 4 | def index 5 | @server_pgpkey = Pgpkey.find_by user_id: 0 6 | @user_pgpkey = Pgpkey.find_by user_id: User.current.id 7 | end 8 | 9 | def create 10 | redirect_to :action => 'index' 11 | 12 | # params conversions 13 | @key = params['key'] 14 | @user_id = params['user_id'].to_i 15 | @secret = params['secret'] 16 | 17 | # sanity checks 18 | flash[:error] = l(:flash_key_exists) and return if key_exists? 19 | flash[:error] = (@user_id == 0 ? l(:flash_private_key_not_valid) : l(:flash_public_key_not_valid)) and 20 | return if not key_valid? 21 | flash[:error] = l(:flash_update_not_allowed) and return if not update_allowed? 22 | flash[:warning] = l(:flash_no_secret) if @user_id == 0 and @secret == '' 23 | 24 | # save key into gpg key ring 25 | gpgme_import = GPGME::Key.import(@key) 26 | flash[:error] = l(:flash_import_error) and return if gpgme_import.imports.empty? 27 | gpgme_key = GPGME::Key.get(gpgme_import.imports[0].fpr) 28 | @fpr = gpgme_key.fingerprint 29 | 30 | # test secret 31 | if @user_id == 0 32 | gpgme = GPGME::Crypto.new 33 | enc = gpgme.encrypt('test', {:recipients => @fpr, :always_trust => true}).to_s 34 | begin 35 | dec = gpgme.decrypt(enc, :password => @secret).to_s 36 | rescue GPGME::Error::BadPassphrase 37 | gpgme_key.delete!(true) 38 | flash.delete(:warning) 39 | flash[:error] = l(:flash_bad_passphrase) and return 40 | end 41 | end 42 | 43 | # save key to db 44 | if Pgpkey.create(:user_id => @user_id, :fpr => @fpr, :secret => @secret) 45 | flash[:notice] = l(:flash_create_succesful) 46 | else 47 | flash[:error] = l(:flash_unknown_error) 48 | end 49 | end 50 | 51 | def delete 52 | redirect_to :action => 'index' 53 | 54 | # params conversions 55 | @user_id = params['user_id'].to_i 56 | 57 | # sanity checks 58 | flash[:error] = l(:flash_key_not_exists) and return if not key_exists? 59 | flash[:error] = l(:flash_update_not_allowed) and return if not update_allowed? 60 | 61 | # remove key from db 62 | key = Pgpkey.find_by user_id: @user_id 63 | fpr = key.fpr 64 | if key.delete 65 | flash[:notice] = l(:flash_delete_succesful) 66 | else 67 | flash[:error] = l(:flash_unknown_error) 68 | end 69 | 70 | # remove key from gpg key ring, if no other reference exists 71 | if not Pgpkey.find_by fpr: fpr 72 | gpgme_key = GPGME::Key.get(fpr) 73 | gpgme_key.delete!(true) 74 | end 75 | end 76 | 77 | def generate 78 | redirect_to :action => 'index' 79 | @user_id = 0 80 | 81 | # sanity checks 82 | flash[:error] = l(:flash_key_exists) and return if key_exists? 83 | flash[:error] = l(:flash_update_not_allowed) and return if not update_allowed? 84 | flash[:warning] = l(:flash_no_secret) if @user_id == 0 and @secret == '' 85 | 86 | # prepare gpg parameter 87 | data = "\n" 88 | data += "Key-Type: " +params['key_type'] +"\n" 89 | data += "Key-Length: " +params['key_length'] +"\n" 90 | data += "Subkey-Type: " +params['subkey_type'] +"\n" 91 | data += "Subkey-Length: " +params['subkey_length'] +"\n" 92 | data += "Name-Real: " +params['name_real'] +"\n" 93 | data += "Name-Comment: " +params['name_comment'] +"\n" unless params['name_comment'].blank? 94 | data += "Name-Email: " +params['name_email'] +"\n" 95 | data += "Expire-Date: " +params['expire_date'] +"\n" 96 | data += "Passphrase: " +params['passphrase'] +"\n" unless params['passphrase'].blank? 97 | data += "" 98 | 99 | # create key and save into gpg key ring 100 | GPGME::Ctx.new.genkey(data) 101 | 102 | # save generated key into db 103 | key = GPGME::Key.find(nil, params['name_email']).first 104 | if Pgpkey.create(:user_id => 0, :fpr => key.fingerprint, :secret => params['passphrase']) 105 | flash[:notice] = l(:flash_generate_succesful) 106 | else 107 | flash[:error] = l(:flash_unknown_error) 108 | end 109 | end 110 | 111 | def key_exists? 112 | Pgpkey.find_by user_id: @user_id 113 | end 114 | 115 | def key_valid? 116 | if @user_id == 0 117 | regex = /^\A\s*-----BEGIN PGP PRIVATE KEY BLOCK-----.*-----END PGP PRIVATE KEY BLOCK-----\s*?\z/m 118 | else 119 | regex = /^\A\s*-----BEGIN PGP PUBLIC KEY BLOCK-----.*-----END PGP PUBLIC KEY BLOCK-----\s*?\z/m 120 | end 121 | @key.match(regex) 122 | end 123 | 124 | def update_allowed? 125 | return true if User.current.admin 126 | return true if User.current.id == @user_id 127 | end 128 | end 129 | -------------------------------------------------------------------------------- /app/helpers/pgpkeys_helper.rb: -------------------------------------------------------------------------------- 1 | module PgpkeysHelper 2 | end 3 | -------------------------------------------------------------------------------- /app/models/pgpkey.rb: -------------------------------------------------------------------------------- 1 | class Pgpkey < ActiveRecord::Base 2 | unloadable 3 | 4 | def public_key 5 | GPGME::Key.get(self.fpr).export(:armor => true).to_s 6 | end 7 | 8 | def metadata 9 | GPGME::Key.get(self.fpr).to_s 10 | end 11 | end 12 | -------------------------------------------------------------------------------- /app/views/mailer/attachments_added.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_attachments_added), 3 | @added_to_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> -------------------------------------------------------------------------------- /app/views/mailer/attachments_added.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_attachments_added) %> 2 | <%= @added_to_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/document_added.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_document_added), 3 | @document_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/document_added.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_document_added) %> 2 | <%= @document_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/issue_add.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_issue_add), 3 | @issue_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/issue_add.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_issue_add) %> 2 | <%= @issue_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/issue_edit.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_issue_edit), 3 | @issue_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/issue_edit.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_issue_edit) %> 2 | <%= @issue_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/message_posted.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_message_posted), 3 | @message_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/message_posted.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_message_posted) %> 2 | <%= @message_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/news_added.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_news_added), 3 | @news_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/news_added.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_news_added) %> 2 | <%= @news_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/news_comment_added.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_news_comment_added), 3 | @news_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/news_comment_added.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_news_comment_added) %> 2 | <%= @news_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/wiki_content_added.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_wiki_content_added), 3 | @wiki_content_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/wiki_content_added.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_wiki_content_added) %> 2 | <%= @wiki_content_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/mailer/wiki_content_updated.filtered.html.erb: -------------------------------------------------------------------------------- 1 |

2 | <%= link_to l(:filtered_mail_wiki_content_updated), 3 | @wiki_content_url %> 4 |

5 | 6 |

7 | <%= l(:filtered_mail_footer) %> 8 | <%= link_to l(:header_openpgp), 9 | Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 10 |

11 | 12 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? %> 13 |

14 | <%= Setting.plugin_openpgp['filtered_mail_footer'].html_safe %> 15 |

16 | <% end %> 17 | -------------------------------------------------------------------------------- /app/views/mailer/wiki_content_updated.filtered.text.erb: -------------------------------------------------------------------------------- 1 | <%= l(:filtered_mail_wiki_content_updated) %> 2 | <%= @wiki_content_url %> 3 | 4 | ---------------------------------------- 5 | 6 | <%= l(:filtered_mail_footer) %> 7 | <%= Setting['protocol'] + '://' + Setting['host_name'] + '/pgp' %> 8 | 9 | <% if not Setting.plugin_openpgp['filtered_mail_footer'].blank? -%> 10 | <%= Setting.plugin_openpgp['filtered_mail_footer'] %> 11 | <% end -%> -------------------------------------------------------------------------------- /app/views/pgpkeys/index.html.erb: -------------------------------------------------------------------------------- 1 |

<%= l(:header_openpgp) %>

2 | 3 | <% if not User.current.logged? %> 4 |

<%= l(:note_login) %>

5 | 6 | <% else %> 7 | 8 |
9 |

<%= User.current.name %> (<%= User.current.mail %>)

10 | <%= field_set_tag '', class: 'box tabular' do %> 11 | <% if @user_pgpkey %> 12 | 13 | <% # user key given %> 14 | <%= form_tag method: "post", action: "delete" do %> 15 |

16 | <%= label_tag 'fpr', l(:label_fingerprint) %> 17 | <%= text_field_tag 'fpr', @user_pgpkey.fpr, size: "40", readonly: true %> 18 |

19 |

20 | <%= label_tag 'metadata', l(:label_metadata) %> 21 | <%= text_area_tag 'meta', @user_pgpkey.metadata, rows: "4", readonly: true %> 22 |

23 |

24 | <%= label_tag 'key', l(:label_public_key) %> 25 | <%= text_area_tag 'key', @user_pgpkey.public_key, rows: "30", readonly: true %> 26 |

27 |

28 | <%= l(:note_user_public_key_given) %>
29 | (<%= l(:note_sent_to) %> <%= User.current.mail %>)
30 |

31 | <%= hidden_field_tag 'user_id', User.current.id %> 32 |

<%= submit_tag l(:button_delete) %>

33 | <% end %> 34 | 35 | <% else %> 36 | 37 | <% # no user key given %> 38 | <%= form_tag method: "post", action: "create" do %> 39 |

40 | <%= label_tag 'key', l(:label_public_key) %> 41 | <%= text_area_tag 'key', nil, :size => "50x30" %> 42 |

43 |

44 | <%= l(:note_user_public_key_missing) %>
45 | (<%= l(:note_sent_to) %> <%= User.current.mail %>)
46 |

47 | <%= hidden_field_tag 'user_id', User.current.id %> 48 |

<%= submit_tag l(:button_create) %>

49 | <% end %> 50 | 51 | <% end %> 52 | <% end %> 53 |
54 | 55 |
56 |

Redmine Server (<%= Setting['mail_from'] %>)

57 | <%= field_set_tag '', class: 'box tabular' do %> 58 | <% if @server_pgpkey %> 59 | 60 | <% # server key given %> 61 | <%= form_tag method: "post", action: "delete" do %> 62 |

63 | <%= label_tag 'fpr', l(:label_fingerprint) %> 64 | <%= text_field_tag 'fpr', @server_pgpkey.fpr, size: "40", readonly: true %> 65 |

66 |

67 | <%= label_tag 'metadata', l(:label_metadata) %> 68 | <%= text_area_tag 'meta', @server_pgpkey.metadata, rows: "4", readonly: true %> 69 |

70 |

71 | <%= label_tag 'key', l(:label_public_key) %> 72 | <%= text_area_tag 'key', @server_pgpkey.public_key, rows: "30", readonly: true %> 73 |

74 |

75 | <%= l(:note_server_public_key_given) %>
76 | (<%= l(:note_sent_to) %> <%= Setting['mail_from'] %>)
77 |

78 | <% if User.current.admin? %> 79 | <%= hidden_field_tag 'user_id', 0 %> 80 |

<%= submit_tag l(:button_delete) %>

81 | <% end %> 82 | <% end %> 83 | 84 | <% else %> 85 | 86 | <% # no server key given %> 87 | <% if not User.current.admin? %> 88 |
<%= l(:note_server_public_key_missing) %>
89 | <% else %> 90 |
<%= l(:note_admin_only) %>
91 | 92 | <% # save existing key %> 93 |

<%= l(:subheader_save_key) %>

94 |
95 | <%= l(:note_cleartext_create) %> 96 | redmine:update_redmine_pgpkey. 97 |
98 | <%= form_tag method: "post", action: "create" do %> 99 |

100 | <%= label_tag 'key', l(:label_private_key) %> 101 | <%= text_area_tag 'key', nil, :size => "50x30" %> 102 |

103 |

104 | <%= label_tag 'secret', l(:label_secret) %> 105 | <%= password_field_tag 'secret', nil, size: "40" %> 106 |

107 |

108 | <%= l(:note_server_private_key_create) %>
109 | (<%= l(:note_receiving_emails) %> Receiving emails)
110 |

111 | <%= hidden_field_tag 'user_id', 0 %> 112 |

<%= submit_tag l(:button_create) %>

113 | <% end %> 114 |
115 | 116 | <% # save existing key %> 117 |

<%= l(:subheader_generate_key) %>

118 |
119 | <%= l(:note_cleartext_generate) %> 120 | redmine:generate_redmine_pgpkey. 121 |
122 | <%= form_tag method: "post", action: "generate" do %> 123 |

124 | <%= label_tag 'key_type', l(:label_key_type) %> 125 | <%= text_field_tag 'key_type', 'RSA', size: "40", readonly: true %> 126 |

127 |

128 | <%= label_tag 'key_length', l(:label_key_length) %> 129 | <%= text_field_tag 'key_length', '2048', size: "40", readonly: true %> 130 |

131 |

132 | <%= label_tag 'subkey_type', l(:label_subkey_type) %> 133 | <%= text_field_tag 'subkey_type', 'RSA', size: "40", readonly: true %> 134 |

135 |

136 | <%= label_tag 'subkey_length', l(:label_subkey_length) %> 137 | <%= text_field_tag 'subkey_length', '2048', size: "40", readonly: true %> 138 |

139 |

140 | <%= label_tag 'name_real', l(:label_name_real) %> 141 | <%= text_field_tag 'name_real', 'Redmine Server', size: "40", readonly: true %> 142 |

143 |

144 | <%= label_tag 'name_comment', l(:label_name_comment) %> 145 | <%= text_field_tag 'name_comment', '', size: "40", readonly: true %> 146 |

147 |

148 | <%= label_tag 'name_email', l(:label_name_email) %> 149 | <%= text_field_tag 'name_email', Setting['mail_from'], size: "40", readonly: true %> 150 |

151 |

152 | <%= label_tag 'expire_date', l(:label_expire_date) %> 153 | <%= text_field_tag 'expire_date', '0', size: "40", readonly: true %> 154 |

155 |

156 | <%= label_tag 'passphrase', l(:label_secret) %> 157 | <%= password_field_tag 'passphrase', nil, size: "40" %> 158 |

159 |

160 | <%= l(:note_server_private_key_generate) %>
161 | (<%= l(:note_receiving_emails) %> Receiving emails)
162 |

163 |

<%= submit_tag l(:button_generate) %>

164 | <% end %> 165 | 166 | <% end %> 167 | 168 | <% end %> 169 | <% end %> 170 |
171 | 172 | <% end %> 173 | -------------------------------------------------------------------------------- /app/views/settings/_openpgp.erb: -------------------------------------------------------------------------------- 1 |

<%= l(:subheader_openpgp_incoming) %>

2 |

3 | <%= label_tag 'settings[signature_needed]', l(:label_signature_needed) %> 4 | <%= check_box_tag 'settings[signature_needed]', nil, 5 | @settings['signature_needed'] %> 6 |

7 | 8 |

<%= l(:subheader_openpgp_outgoing) %>

9 |

10 | <%= label_tag 'settings[activation]', l(:label_openpgp_activation) %> 11 | <%= select_tag 'settings[activation]', 12 | options_for_select([ 13 | [l(:option_activation_all), "all"], 14 | [l(:option_activation_project), "project"], 15 | [l(:option_activation_none), "none"] 16 | ], 17 | @settings['activation'] 18 | ) %> 19 |

20 |

21 | <%= label_tag 'settings[unencrypted_mails]', l(:label_unencrypted_mails) %> 22 | <%= select_tag 'settings[unencrypted_mails]', 23 | options_for_select([ 24 | [l(:option_unencrypted_mails_blocked), "blocked"], 25 | [l(:option_unencrypted_mails_filtered), "filtered"], 26 | [l(:option_unencrypted_mails_unchanged), "unchanged"] 27 | ], 28 | @settings['unencrypted_mails'] 29 | ) %> 30 |

31 |

32 | <%= label_tag 'settings[filtered_mail_footer]', l(:label_filtered_mail_footer) %> 33 | <%= text_area_tag 'settings[filtered_mail_footer]', 34 | @settings['filtered_mail_footer'], 35 | {:size => "160x10"} %> 36 |

37 | -------------------------------------------------------------------------------- /config/locales/de.yml: -------------------------------------------------------------------------------- 1 | de: 2 | header_openpgp: PGP Schlüsselverwaltung 3 | subheader_openpgp_incoming: Eingehende Mails 4 | subheader_openpgp_outgoing: Ausgehende Mails 5 | subheader_save_key: Existierenden Schlüssel hinzufügen 6 | subheader_generate_key: Neuen Schlüssel generieren 7 | label_openpgp_activation: Plugin Aktivierung 8 | label_unencrypted_mails: Unverschlüsselte Mails 9 | label_signature_needed: Nur valide Signaturen 10 | label_filtered_mail_footer: Angehängte Nachricht in gefilterten Mails 11 | label_public_key: Öffentlicher PGP Schlüssel 12 | label_private_key: Privater PGP Schlüssel 13 | label_fingerprint: Fingerabdruck 14 | label_metadata: Metadaten 15 | label_key_type: Schlüsseltyp 16 | label_key_length: Schlüssellänge 17 | label_subkey_type: Unterschlüsseltyp 18 | label_subkey_length: Unterschlüssellänge 19 | label_name_real: Name 20 | label_name_comment: Kommentar 21 | label_name_email: Email 22 | label_expire_date: Ablaufdatum 23 | label_secret: Passphrase 24 | option_activation_all: für alle Projekte 25 | option_activation_project: abhängig von Projekteinstellungen 26 | option_activation_none: deaktiviert 27 | option_unencrypted_mails_blocked: blockiert 28 | option_unencrypted_mails_filtered: gefiltert 29 | option_unencrypted_mails_unchanged: unverändert 30 | button_create: Speichern 31 | button_delete: Löschen 32 | button_generate: Generieren 33 | note_login: Bitte einloggen, um die PGP Schlüssel zu verwalten. 34 | note_admin_only: Nur Administratoren können den privaten Schlüssel und die Passphrase für den Redmine Server verändern 35 | note_user_public_key_missing: Füge Deinen öffentlichen PGP Schlüssel hier hinzu, um verschlüsselte Mails zu erhalten 36 | note_user_public_key_given: Mit diesem PGP Schlüssel werden Mails von Redmine verschlüsselt 37 | note_server_public_key_missing: Kein Schlüssel hinterlegt. Benachrichtige bitte die Administratoren, falls Du Mails an Redmine verschlüsseln möchtest. 38 | note_server_public_key_given: Benutze diesen öffentlichen PGP Schlüssel, um Mails an Redmine zu verschlüsseln 39 | note_server_private_key_create: Füge einen privaten PGP Schlüssel für den Redmine Server hinzu, um verschlüsselte Mails an Redmine zu ermöglichen 40 | note_server_private_key_generate: Generiere einen privaten PGP Schlüssel für den Redmine Server, um verschlüsselte Mails an Redmine zu ermöglichen 41 | note_receiving_emails: Die Annahme von Emails muss in Redmine konfiguriert sein, siehe 42 | note_cleartext_create: "Der private Schlüssel und die Passphrase werden im Klartext übertragen! Verwende zumindest https oder nutze besser den serverseitigen rake taks: " 43 | note_cleartext_generate: "Die Passphrase wird im Klartext übertragen! Verwende zumindest https oder nutze besser den serverseitigen rake taks: " 44 | note_sent_to: gesendet an 45 | flash_public_key_not_valid: PGP Schlüssel ist ungültig (er sollte mit '-----BEGIN PGP PUBLIC KEY BLOCK-----' starten und mit '-----END PGP PUBLIC KEY BLOCK-----' enden) 46 | flash_private_key_not_valid: PGP Schlüssel ist ungültig (er sollte mit '-----BEGIN PGP PRIVATE KEY BLOCK-----' starten und mit '-----END PGP PRIVATE KEY BLOCK-----' enden) 47 | flash_bad_passphrase: Passphrase war falsch (bitte nochmal versuchen) 48 | flash_key_exists: Schlüssel existiert schon (bitte zuerst löschen) 49 | flash_key_not_exists: Schlüssel existiert nicht 50 | flash_update_not_allowed: Operation nicht erlaubt (bitte nicht weiter versuchen) 51 | flash_import_error: Fehler beim Importieren des Schlüssels (bitte nochmal versuchen oder die Administratoren benachrichtigen) 52 | flash_unknown_error: Unbekannter Fehler (bitte nochmal versuchen oder die Administratoren benachrichtigen) 53 | flash_no_secret: Keine Passphrase angegeben (kein Problem, aber bist Du Dir sicher?) 54 | flash_create_succesful: PGP Schlüssel erfolgreich gepeichert 55 | flash_delete_succesful: PGP Schlüssel erfolgreich gelöscht 56 | flash_generate_succesful: PGP Schlüssel erfolgreich generiert 57 | filtered_mail_footer: "Diese Mail wurde aus Gründen der Sicherheit gefiltert. Folge diesem Link und füge Deinen öffentlichen PGP Schlüssel hinzu, um ungefilterte, verschlüsselte Mails zu erhalten:" 58 | filtered_mail_attachments_added: Anhänge hinzugefügt 59 | filtered_mail_document_added: Dokument hinzugefügt 60 | filtered_mail_issue_add: Ticket hinzugefügt 61 | filtered_mail_issue_edit: Ticket bearbeitet 62 | filtered_mail_message_posted: Nachricht hinzugefügt 63 | filtered_mail_news_added: Neuigkeit hinzugefügt 64 | filtered_mail_news_comment_added: Kommentar hinzugefügt 65 | filtered_mail_wiki_content_added: Seite hinzugefügt 66 | filtered_mail_wiki_content_updated: Seite editiert 67 | -------------------------------------------------------------------------------- /config/locales/en.yml: -------------------------------------------------------------------------------- 1 | en: 2 | header_openpgp: PGP Keymanagement 3 | subheader_openpgp_incoming: Incoming 4 | subheader_openpgp_outgoing: Outgoing 5 | subheader_save_key: Save existing key 6 | subheader_generate_key: Generate new key 7 | label_openpgp_activation: Plugin activation 8 | label_unencrypted_mails: Unencrypted mails 9 | label_signature_needed: Valid signatures only 10 | label_filtered_mail_footer: Custom footer of filtered mails 11 | label_public_key: Public PGP key 12 | label_private_key: Private PGP key 13 | label_fingerprint: Fingerprint 14 | label_metadata: Metadata 15 | label_key_type: Key type 16 | label_key_length: Key length 17 | label_subkey_type: Subkey type 18 | label_subkey_length: Subkey length 19 | label_name_real: Name 20 | label_name_comment: Comment 21 | label_name_email: Email 22 | label_expire_date: Expire date 23 | label_secret: Passphrase 24 | option_activation_all: for all projects 25 | option_activation_project: dependant on project settings 26 | option_activation_none: deactivated 27 | option_unencrypted_mails_blocked: blocked 28 | option_unencrypted_mails_filtered: filtered 29 | option_unencrypted_mails_unchanged: unchanged 30 | button_create: Save 31 | button_delete: Remove 32 | button_generate: Generate 33 | note_login: Please log in to manage PGP keys. 34 | note_admin_only: Only administrators will be able to change the private PGP key and passphrase for the redmine server 35 | note_user_public_key_missing: Add your public PGP key here to recieve encrypted mails by redmine 36 | note_user_public_key_given: This PGP key is used to encrypt mails by redmine 37 | note_server_public_key_missing: No key given. Please contact your administrator if you want to send encrypted mails to redmine. 38 | note_server_public_key_given: Use this public PGP key to encrypt mails for redmine 39 | note_server_private_key_create: Add a private PGP key for redmine to enable encrytion of mails sent to redmine 40 | note_server_private_key_generate: Generate a private PGP key for redmine to enable encrytion of mails sent to redmine 41 | note_receiving_emails: recieving emails must be configured within redmine, see 42 | note_cleartext_create: "The private key and passphrase will be sent in cleartext! Ensure using https or better use the serverside rake task: " 43 | note_cleartext_generate: "The passphrase will be sent in cleartext! Ensure using https or better use the serverside rake task: " 44 | note_sent_to: sent to 45 | flash_public_key_not_valid: PGP key not valid (it should start with '-----BEGIN PGP PUBLIC KEY BLOCK-----' and end with '-----END PGP PUBLIC KEY BLOCK-----') 46 | flash_private_key_not_valid: PGP key not valid (it should start with '-----BEGIN PGP PRIVATE KEY BLOCK-----' and end with '-----END PGP PRIVATE KEY BLOCK-----') 47 | flash_bad_passphrase: Passphrase was wrong (please try again) 48 | flash_key_exists: Key does exist already (please delete it first) 49 | flash_key_not_exists: Key does not exist 50 | flash_update_not_allowed: Operation not allowed (please don't try) 51 | flash_import_error: Error importing the key (please try again or contact your administrator) 52 | flash_unknown_error: Unkown error (please try again or contact your administrator) 53 | flash_no_secret: Passphrase is empty (no problem, but are you sure?) 54 | flash_create_succesful: PGP key successfully saved 55 | flash_delete_succesful: PGP key successfully deleted 56 | flash_generate_succesful: PGP key successfully generated 57 | filtered_mail_footer: "This mail was filtered for enhanced security. Follow this link and add your public PGP key to receive unfiltered encrypted mails:" 58 | filtered_mail_attachments_added: Attachements added 59 | filtered_mail_document_added: Document added 60 | filtered_mail_issue_add: Issue added 61 | filtered_mail_issue_edit: Issue edited 62 | filtered_mail_message_posted: Message added 63 | filtered_mail_news_added: News added 64 | filtered_mail_news_comment_added: Comment added 65 | filtered_mail_wiki_content_added: Page added 66 | filtered_mail_wiki_content_updated: Page edited -------------------------------------------------------------------------------- /config/routes.rb: -------------------------------------------------------------------------------- 1 | # Plugin's routes 2 | # See: http://guides.rubyonrails.org/routing.html 3 | 4 | get 'pgp', :to => 'pgpkeys#index' 5 | post 'pgp/create', :to => 'pgpkeys#create' 6 | post 'pgp/delete', :to => 'pgpkeys#delete' 7 | post 'pgp/generate', :to => 'pgpkeys#generate' -------------------------------------------------------------------------------- /db/migrate/001_create_pgpkeys.rb: -------------------------------------------------------------------------------- 1 | class CreatePgpkeys < ActiveRecord::Migration 2 | def change 3 | create_table :pgpkeys do |t| 4 | t.integer :user_id 5 | t.string :fpr 6 | t.string :secret 7 | end 8 | end 9 | end 10 | -------------------------------------------------------------------------------- /init.rb: -------------------------------------------------------------------------------- 1 | #!/bin/env ruby 2 | # encoding: utf-8 3 | 4 | require 'gpgme' 5 | require 'mail-gpg' 6 | 7 | Redmine::Plugin.register :openpgp do 8 | name 'OpenPGP' 9 | author 'Alexander Blum' 10 | description 'Email encryption with the OpenPGP standard' 11 | version '1.0' 12 | author_url 'mailto:a.blum@free-reality.net' 13 | url 'https://github.com/C3S/redmine_openpgp' 14 | settings(:default => { 15 | 'signature_needed' => false, 16 | 'encryption_scope' => 'project', 17 | 'unencrypted_mails' => 'filtered', 18 | 'filtered_mail_footer' => '' 19 | }, :partial => 'settings/openpgp') 20 | project_module :openpgp do 21 | permission :block_email, { :openpgp => :show } 22 | end 23 | menu :account_menu, :pgpkeys, { :controller => 'pgpkeys', :action => 'index' }, 24 | :caption => 'PGP', :after => :my_account, 25 | :if => Proc.new { User.current.logged? } 26 | end 27 | 28 | # encrypt outgoing mails 29 | ActionDispatch::Callbacks.to_prepare do 30 | require_dependency 'mailer' 31 | Mailer.send(:include, EncryptMails) 32 | end 33 | 34 | # decrypt received mails 35 | ActionDispatch::Callbacks.to_prepare do 36 | require_dependency 'mail_handler' 37 | MailHandler.send(:include, DecryptMails) 38 | end 39 | -------------------------------------------------------------------------------- /lib/decrypt_mails.rb: -------------------------------------------------------------------------------- 1 | module DecryptMails 2 | 3 | def self.included(base) # :nodoc: 4 | base.send(:include, InstanceMethods) 5 | base.class_eval do 6 | alias_method_chain :receive, :encryption 7 | end 8 | end 9 | 10 | module InstanceMethods 11 | 12 | def receive_with_encryption(email, options={}) 13 | 14 | # encrypt and check validity of signature 15 | if email.encrypted? 16 | email = email.decrypt( 17 | :password => Pgpkey.find_by(:user_id => 0), 18 | :verify => true 19 | ) 20 | valid = email.signature_valid? 21 | signatures = email.signatures 22 | else 23 | if email.signed? 24 | verified = email.verify 25 | valid = verified.signature_valid? 26 | signatures = verified.signatures 27 | else 28 | valid = false 29 | end 30 | end 31 | 32 | # compare identity of signature with sender 33 | if valid 34 | valid = false 35 | sender_email = email.from.to_a.first.to_s.strip 36 | user = User.find_by_mail sender_email if sender_email.present? 37 | key = Pgpkey.find_by user_id: user.id 38 | signatures.each do |s| 39 | valid = true if key.fpr == s.fpr 40 | end if not signatures.empty? 41 | end 42 | 43 | # error on invalid signature 44 | if Setting.plugin_openpgp['signature_needed'] and not valid 45 | if logger 46 | logger.info "MailHandler: ignoring emails with invalid signature" 47 | end 48 | return false 49 | end 50 | 51 | receive_without_encryption(email, options) 52 | 53 | end 54 | 55 | end 56 | end -------------------------------------------------------------------------------- /lib/encrypt_mails.rb: -------------------------------------------------------------------------------- 1 | module EncryptMails 2 | 3 | def self.included(base) # :nodoc: 4 | base.send(:include, InstanceMethods) 5 | base.class_eval do 6 | alias_method_chain :mail, :relocation 7 | end 8 | end 9 | 10 | module InstanceMethods 11 | 12 | # action names to be processed by this plugin 13 | def actions 14 | [ 15 | 'attachments_added', 16 | 'document_added', 17 | 'issue_add', 18 | 'issue_edit', 19 | 'message_posted', 20 | 'news_added', 21 | 'news_comment_added', 22 | 'wiki_content_added', 23 | 'wiki_content_updated' 24 | ] 25 | end 26 | 27 | # dispatched mail method 28 | def mail_with_relocation(headers={}, &block) 29 | 30 | # pass unchanged, if action does not match or plugin is inactive 31 | act = Setting.plugin_openpgp['activation'] 32 | return mail_without_relocation(headers, &block) if 33 | act == 'none' or not actions.include? @_action_name or 34 | (act == 'project' and not project.try('module_enabled?', 'openpgp')) 35 | 36 | # relocate recipients 37 | recipients = relocate_recipients(headers) 38 | header = @_message.header.to_s 39 | 40 | # render and deliver encrypted mail 41 | reset(header) 42 | m = mail_without_relocation prepare_headers( 43 | headers, recipients[:encrypted], encrypt = true, sign = true 44 | ) do |format| 45 | format.text 46 | end 47 | m.deliver 48 | 49 | # render and deliver filtered mail 50 | reset(header) 51 | tpl = @_action_name + '.filtered' 52 | m = mail_without_relocation prepare_headers( 53 | headers, recipients[:filtered], encrypt = false, sign = true 54 | ) do |format| 55 | format.text { render tpl } 56 | format.html { render tpl } unless Setting.plain_text_mail? 57 | end 58 | m.deliver 59 | 60 | # render unchanged mail (deliverd by calling method) 61 | reset(header) 62 | m = mail_without_relocation prepare_headers( 63 | headers, recipients[:unchanged], encrypt = false, sign = false 64 | ) do |format| 65 | format.text 66 | format.html unless Setting.plain_text_mail? 67 | end 68 | 69 | m 70 | 71 | end 72 | 73 | # get project dependent on action and object 74 | def project 75 | 76 | case @_action_name 77 | when 'attachments_added' 78 | @attachments.first.project 79 | when 'document_added' 80 | @document.project 81 | when 'issue_add', 'issue_edit' 82 | @issue.project 83 | when 'message_posted' 84 | @message.project 85 | when 'news_added', 'news_comment_added' 86 | @news.project 87 | when 'wiki_content_added', 'wiki_content_updated' 88 | @wiki_content.project 89 | else 90 | nil 91 | end 92 | 93 | end 94 | 95 | # relocates reciepients (to, cc) of message 96 | def relocate_recipients(headers) 97 | 98 | # hash to be returned 99 | recipients = { 100 | :encrypted => {:to => [], :cc => []}, 101 | :blocked => {:to => [], :cc => []}, 102 | :filtered => {:to => [], :cc => []}, 103 | :unchanged => {:to => [], :cc => []}, 104 | :lost => {:to => [], :cc => []} 105 | } 106 | 107 | # relocation of reciepients 108 | [:to, :cc].each do |field| 109 | headers[field].each do |user| 110 | 111 | # encrypted 112 | unless Pgpkey.find_by(user_id: user.id).nil? 113 | recipients[:encrypted][field].push user and next 114 | end 115 | 116 | # unencrypted 117 | case Setting.plugin_openpgp['unencrypted_mails'] 118 | when 'blocked' 119 | recipients[:blocked][field].push user 120 | when 'filtered' 121 | recipients[:filtered][field].push user 122 | when 'unchanged' 123 | recipients[:unchanged][field].push user 124 | else 125 | recipients[:lost][field].push user 126 | end 127 | 128 | end unless headers[field].blank? 129 | end 130 | 131 | recipients 132 | 133 | end 134 | 135 | # resets the mail for sending mails multiple times 136 | def reset(header) 137 | 138 | @_mail_was_called = false 139 | @_message = Mail.new 140 | @_message.header header 141 | 142 | end 143 | 144 | # prepares the headers for different configurations 145 | def prepare_headers(headers, recipients, encrypt, sign) 146 | 147 | h = headers.deep_dup 148 | 149 | # headers for recipients 150 | h[:to] = recipients[:to] 151 | h[:cc] = recipients[:cc] 152 | 153 | # headers for gpg 154 | h[:gpg] = { 155 | encrypt: false, 156 | sign: false 157 | } 158 | 159 | # headers for encryption 160 | if encrypt 161 | h[:gpg][:encrypt] = true 162 | # add pgp keys for emails 163 | h[:gpg][:keys] = {} 164 | [:to, :cc].each do |field| 165 | h[field].each do |user| 166 | user_key = Pgpkey.find_by user_id: user.id 167 | unless user_key.nil? 168 | h[:gpg][:keys][user.mail] = user_key.fpr 169 | end 170 | end unless h[field].blank? 171 | end 172 | end 173 | 174 | # headers for signature 175 | if sign 176 | server_key = Pgpkey.find_by(:user_id => 0) 177 | unless server_key.nil? 178 | h[:gpg][:sign] = true 179 | h[:gpg][:sign_as] = Setting['mail_from'] 180 | h[:gpg][:password] = server_key.secret 181 | end 182 | end 183 | 184 | h 185 | 186 | end 187 | 188 | end 189 | end 190 | -------------------------------------------------------------------------------- /lib/tasks/generate_redmine_pgpkey.rake: -------------------------------------------------------------------------------- 1 | desc <<-END_DESC 2 | Generate the private PGP key for the redmine server. 3 | Warning: will override and delete the existing one. 4 | 5 | Available options: 6 | * secret => passphrase (interactive, if not given) 7 | 8 | Example: 9 | RAILS_ENV="production" rake redmine:generate_redmine_pgpkey 10 | RAILS_ENV="production" rake redmine:generate_redmine_pgpkey secret="passphrase" 11 | END_DESC 12 | 13 | namespace :redmine do 14 | task :generate_redmine_pgpkey => :environment do |task| 15 | keyfile = ENV['keyfile'] 16 | @secret = ENV['secret'] 17 | 18 | # sanity checks 19 | puts 'Warning: passphrase is empty (no problem, but are you sure?)' if @secret == "" 20 | 21 | # interactive mode: secret 22 | if @secret == nil 23 | print "Enter secret: " 24 | STDOUT.flush 25 | @secret = STDIN.noecho(&:gets).chomp! 26 | puts 27 | puts 'Warning: passphrase is empty (no problem, but are you sure?)' if @secret == "" 28 | end 29 | 30 | # remove old key from db and from gpg ring, if present 31 | old_key = Pgpkey.find_by user_id: 0 32 | if old_key 33 | old_fpr = old_key.fpr 34 | old_key.delete 35 | puts '... removed old key from db.' 36 | if not Pgpkey.find_by fpr: old_fpr 37 | gpgme_key = GPGME::Key.get(old_fpr) 38 | gpgme_key.delete!(true) 39 | puts '... removed old key from gpg key ring.' 40 | else 41 | puts 'Warning: old key not removed (still referenced by a user)' 42 | end 43 | end 44 | 45 | # prepare gpg parameter 46 | params = { 47 | :key_type => 'RSA', 48 | :key_length => '2048', 49 | :subkey_type => 'RSA', 50 | :subkey_length => '2048', 51 | :name_real => 'Redmine Server', 52 | :name_comment => '', 53 | :name_email => Setting['mail_from'], 54 | :expire_date => '0', 55 | :passphrase => @secret 56 | } 57 | data = "\n" 58 | data += "Key-Type: " +params[:key_type] +"\n" 59 | data += "Key-Length: " +params[:key_length] +"\n" 60 | data += "Subkey-Type: " +params[:subkey_type] +"\n" 61 | data += "Subkey-Length: " +params[:subkey_length] +"\n" 62 | data += "Name-Real: " +params[:name_real] +"\n" 63 | data += "Name-Comment: " +params[:name_comment] +"\n" unless params['name_comment'].blank? 64 | data += "Name-Email: " +params[:name_email] +"\n" 65 | data += "Expire-Date: " +params[:expire_date] +"\n" 66 | data += "Passphrase: " +params[:passphrase] +"\n" unless params['passphrase'].blank? 67 | data += "" 68 | puts '... PGP key parameters built.' 69 | 70 | # create key and save into gpg key ring 71 | GPGME::Ctx.new.genkey(data) 72 | puts '... PGP key generated and saved into gpg key ring.' 73 | 74 | # save generated key into db 75 | key = GPGME::Key.find(nil, params[:name_email]).first 76 | if Pgpkey.create(:user_id => 0, :fpr => key.fingerprint, :secret => params['passphrase']) 77 | puts '... saved generated key to db.' 78 | else 79 | abort "Error: Unkown error." 80 | end 81 | 82 | puts 'PGP key successfully generated. Exiting.' 83 | end 84 | end 85 | -------------------------------------------------------------------------------- /lib/tasks/update_redmine_pgpkey.rake: -------------------------------------------------------------------------------- 1 | desc <<-END_DESC 2 | Update the private PGP key and passphrase for the redmine server. 3 | Warning: will override and delete the existing one. 4 | 5 | Available options: 6 | * key => absolute path to key file (interactive, if not given) 7 | * secret => passphrase (interactive, if not given) 8 | 9 | Example: 10 | RAILS_ENV="production" rake redmine:update_redmine_pgpkey 11 | RAILS_ENV="production" rake redmine:update_redmine_pgpkey keyfile="/path/to/key.asc" secret="passphrase" 12 | END_DESC 13 | 14 | namespace :redmine do 15 | task :update_redmine_pgpkey => :environment do |task| 16 | keyfile = ENV['keyfile'] 17 | @secret = ENV['secret'] 18 | 19 | # sanity checks 20 | puts 'Warning: passphrase is empty (no problem, but are you sure?)' if @secret == "" 21 | abort 'Error: cannot access "'+keyfile+'". Wrong path?' if not keyfile.blank? and not File.file? keyfile 22 | 23 | # interactive mode: keyfile 24 | if keyfile.blank? 25 | while true 26 | print "Enter absolute path to key file: " 27 | STDOUT.flush 28 | keyfile = STDIN.gets.chomp! 29 | abort 'Abort.' if keyfile.empty? 30 | break if File.file? keyfile 31 | puts 'Error: cannot access "'+keyfile+'". Wrong path?' 32 | end 33 | end 34 | puts '... "'+keyfile+'" does exist.' 35 | 36 | # interactive mode: secret 37 | if @secret == nil 38 | print "Enter secret: " 39 | STDOUT.flush 40 | @secret = STDIN.noecho(&:gets).chomp! 41 | puts 42 | puts 'Warning: passphrase is empty (no problem, but are you sure?)' if @secret == "" 43 | end 44 | 45 | # open and validate keyfile 46 | @key = File.open(keyfile, "rb").read 47 | regex = /^\A\s*-----BEGIN PGP PRIVATE KEY BLOCK-----.*-----END PGP PRIVATE KEY BLOCK-----\s*?\z/m 48 | abort 'Error: PGP key not valid (it should start with "-----BEGIN PGP PRIVATE KEY BLOCK-----" and end with "-----END PGP PRIVATE KEY BLOCK-----")' if not @key.match(regex) 49 | puts '... PGP key seems to be valid.' 50 | 51 | # remove old key from db and from gpg ring, if present 52 | old_key = Pgpkey.find_by user_id: 0 53 | if old_key 54 | old_fpr = old_key.fpr 55 | old_key.delete 56 | puts '... removed old key from db.' 57 | if not Pgpkey.find_by fpr: old_fpr 58 | gpgme_key = GPGME::Key.get(old_fpr) 59 | gpgme_key.delete!(true) 60 | puts '... removed old key from gpg key ring.' 61 | else 62 | puts 'Wanring: old key not removed (still referenced by a user)' 63 | end 64 | end 65 | 66 | # save new key into gpg key ring 67 | gpgme_import = GPGME::Key.import(@key) 68 | abort 'Error: import of the key into gpg key ring failed.' if gpgme_import.imports.empty? 69 | puts '... PGP key imported into gpg key ring.' 70 | gpgme_key = GPGME::Key.get(gpgme_import.imports[0].fpr) 71 | @fpr = gpgme_key.fingerprint 72 | 73 | # test secret 74 | gpgme = GPGME::Crypto.new 75 | enc = gpgme.encrypt('test', {:recipients => @fpr, :always_trust => true}).to_s 76 | begin 77 | dec = gpgme.decrypt(enc, :password => @secret).to_s 78 | rescue GPGME::Error::BadPassphrase 79 | gpgme_key.delete!(true) 80 | abort "Error: Passphrase was wrong." 81 | end 82 | puts '... passphrase is correct.' 83 | 84 | # save new key to db 85 | if Pgpkey.create(:user_id => 0, :fpr => @fpr, :secret => @secret) 86 | puts '... saved new key to db.' 87 | else 88 | abort "Error: Unkown error." 89 | end 90 | 91 | puts 'PGP key successfully saved. Exiting.' 92 | end 93 | end 94 | -------------------------------------------------------------------------------- /test/functional/pgpkeys_controller_test.rb: -------------------------------------------------------------------------------- 1 | require File.expand_path('../../test_helper', __FILE__) 2 | 3 | class PgpkeysControllerTest < ActionController::TestCase 4 | # Replace this with your real tests. 5 | def test_truth 6 | assert true 7 | end 8 | end 9 | -------------------------------------------------------------------------------- /test/pgp.passphrase.private.asc: -------------------------------------------------------------------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VG9xPKA1gLrKQfmk1dRBzJjYyYU+LNclu 51 | ZodziT1NykBjH6r/XBSDFxVNKu0QznyJAR8EGAECAAkFAlXaxSsCGwwACgkQkl2e 52 | H2ELv2JJoQf+ON9/llw4ye6vPepmwpDEmmzS1TlzoSjDXFF0ahlf15Zu9rXhekTv 53 | xxQPzeGv4nPN6ZNut35CVTky/da6HFDHexdEEQpKHEzcVdZFOvRqs61xgbGVUarc 54 | A3ZdMv946d6cH4SEk4jG2SM9XSqMpYtS8Jx9nCQD5qpEViyPmB0T9yJiIdnVxtd/ 55 | fijn5hTl1sRw1Z6bZ3OH2ssFDLSo7wnh0u+8hmYaCN9R4IqpPHKSAhuYkbWGwx+t 56 | YHKZzg0IlesR3o0VnAI1TPh6t2JLUQY2qZ+YGfdAPaLdGbtzl3RefL7B7i99TD8U 57 | BFD2P5YZg7ykb4FNYQBl44yi5IhjKgyAlQ== 58 | =cA8J 59 | -----END PGP PRIVATE KEY BLOCK----- 60 | -------------------------------------------------------------------------------- /test/pgp.passphrase.public.asc: -------------------------------------------------------------------------------- 1 | -----BEGIN PGP PUBLIC KEY BLOCK----- 2 | Version: GnuPG v1 3 | 4 | mQENBFXaxSsBCADYBi8VaIXFWu/J8WEErH/HQ7ZIHenGW68fgeiKysrL0GlrlJTl 5 | f5XX/pLZzLHFTMxgTlQ7ECmEQd+KlODQE27VPKltWC1xT73Qq9UILOI6JdG+hT4V 6 | jdxBKI0Xque4sUqQJSj3/PzgoEIiRf7bpcqH0YUOtF8RI0s3mc4HTA10859GXA+m 7 | duG/LOBKLdyBTR3Qj+M6qVesecCa9uAXQZ54sPjSA9fTwee8Jcw7VpE0CWJUvbEU 8 | AXz1lU3dh62j7gionHxAasBhtzLIEPLy6esBJrLWZhLpthfNW2ccZujL0iGGaNju 9 | OOd6MJeFNm7jGIeBOokG2CynFUIIae5hOD67ABEBAAG0KFBhc3NwaHJhc2UgVGVz 10 | dCA8cGFzc3BocmFzZUBleGFtcGxlLm5ldD6JATgEEw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HDVnptnc4faywUMtKjvCeHS77yGZhoI31Hg 27 | iqk8cpICG5iRtYbDH61gcpnODQiV6xHejRWcAjVM+Hq3YktRBjapn5gZ90A9ot0Z 28 | u3OXdF58vsHuL31MPxQEUPY/lhmDvKRvgU1hAGXjjKLkiGMqDICV 29 | =OaGq 30 | -----END PGP PUBLIC KEY BLOCK----- 31 | -------------------------------------------------------------------------------- /test/pgp.server.private.asc: -------------------------------------------------------------------------------- 1 | -----BEGIN PGP PRIVATE KEY BLOCK----- 2 | Version: GnuPG v1 3 | 4 | lQOYBFXY6w4BCADMOAkUgRcxl9JrLmOGIvuZFcfAbA6RweoGTSKe4zqAcsxH7Z17 5 | xk5vpW+Bv+mORKIvo6ZFvzXzauzy/3Q6HXsbO4Hp+Fi8FULhO0kzXE2DWrz5Rg25 6 | suEh39haUHookpNx6vYMwFwAE5E/pGYU1WuFzk/pikHEdas7rmchQkwGMq0javlc 7 | DeGjsivqHHm+njVuNkoM0Rt72+dBytNLta88Pducftvm+2qIAuiwd6VrZplJroTJ 8 | gVDvGX42cDe2Yipa44+wHx1wzr7WvF0BBGjX1sRRoh5S3eZOHijl7hSvGG/2rqwl 9 | Z7pBC0TUXUAyYY8vOLPFmKjT46b/7k5l8wQxABEBAAEAB/4s1SptJW/lk8p+fDce 10 | JgTtFSJ+pFpIdnU9f+aXUhQwScN+EPSvTRhAG2YQ6oRIFtoyMi+ZBUK/VxyAtkMa 11 | VQmHL3e0WTCFzfcaQi0uSNe9fAibgt0VhOc2zBEPtrYyvQcAjdAJeZtY6vLKsXk1 12 | nqrVu7bAcvlAO4LlfcKnQwo0m7vtJbFo7YgSJ7wC4HYU1kH2JVY7zYpgAt85kSou 13 | CEcpnPx+9SdTJrs0iZftqy92Iurxfjm15O8bgTJO3byW9VWNMK5XCVFhIKU1R/W/ 14 | 8KnsJJKm2fjR1mZFVNjOCEVKSIFEvM+JmpwL80AUD5sSDqQvwEsMLAAY1We/cIsD 15 | aYjXBADY2N1ftHA42UYeXMC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Alv9TyCtRlIjX1 47 | ad//BADPFt0OeyrJCaK+16eVnrA/7WpTy0S8WSe4aTujtJWGXTmYnLotUtAAaA27 48 | KOKNn5ZwcmYROAj6I57EAJmHOCRUWwOMj0+FgVNiKWmSCe9OqUpQdhnWmLCcdorO 49 | 9Mf40428da1dZ55kGEKOtyQbeCzwkH+Ax5wUqJTKw8vpt/p4yD4TiQEfBBgBAgAJ 50 | BQJV2OsOAhsMAAoJELyE1aheTXM+J4YIAIIMwbSk5Wcy4fDQZrEkhEoFgljQsAM3 51 | mFfmHfhQnpeMJNQLYcQuQtDrfu0HpMjMEI0lts126lHd2mSEJxv5FQXZa3CKP/yg 52 | dhMNaWGx1nvUEG4X1ZTlnvjg3bOHiQiyE/xtM81JyKCwm1r9aREHdsaQ7OtADga/ 53 | hUCLUGeV83HDpl5XRyxe/zpczuNIYSWZT8+dcyvHbkeFPCGP4inzgKTWYWsjl4Jk 54 | oKJNPXdzkJSDqPW+WrUlMATPFhQ121ApP4PgmIKmRo2qGF4wZf4WRB8LBmKgPuYb 55 | 1MIlAi+wX5HgSvPklKng8TS1PRMQmiYSyiqTeuqFm6jtf5GoYQx5AZk= 56 | =LyJ/ 57 | -----END PGP PRIVATE KEY BLOCK----- 58 | -------------------------------------------------------------------------------- /test/pgp.server.public.asc: -------------------------------------------------------------------------------- 1 | -----BEGIN PGP PUBLIC KEY BLOCK----- 2 | Version: GnuPG v1 3 | 4 | mQENBFXY6w4BCADMOAkUgRcxl9JrLmOGIvuZFcfAbA6RweoGTSKe4zqAcsxH7Z17 5 | xk5vpW+Bv+mORKIvo6ZFvzXzauzy/3Q6HXsbO4Hp+Fi8FULhO0kzXE2DWrz5Rg25 6 | suEh39haUHookpNx6vYMwFwAE5E/pGYU1WuFzk/pikHEdas7rmchQkwGMq0javlc 7 | DeGjsivqHHm+njVuNkoM0Rt72+dBytNLta88Pducftvm+2qIAuiwd6VrZplJroTJ 8 | gVDvGX42cDe2Yipa44+wHx1wzr7WvF0BBGjX1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QuQtDrfu0HpMjMEI0lts126lHd2mSEJxv5FQXZa3CKP/ygdhMNaWGx 25 | 1nvUEG4X1ZTlnvjg3bOHiQiyE/xtM81JyKCwm1r9aREHdsaQ7OtADga/hUCLUGeV 26 | 83HDpl5XRyxe/zpczuNIYSWZT8+dcyvHbkeFPCGP4inzgKTWYWsjl4JkoKJNPXdz 27 | kJSDqPW+WrUlMATPFhQ121ApP4PgmIKmRo2qGF4wZf4WRB8LBmKgPuYb1MIlAi+w 28 | X5HgSvPklKng8TS1PRMQmiYSyiqTeuqFm6jtf5GoYQx5AZk= 29 | =xuI4 30 | -----END PGP PUBLIC KEY BLOCK----- 31 | -------------------------------------------------------------------------------- /test/pgp.user.private.asc: -------------------------------------------------------------------------------- 1 | -----BEGIN PGP PRIVATE KEY BLOCK----- 2 | Version: GnuPG v1 3 | 4 | lQOYBFXY6ywBCADgZYPypF61Fncr96dsWgLH+u94+iTPTiOdlneYqMKz3Ti2MDE1 5 | jPj5VHwT2x1F1+g31ASrzWX1SIq63HaJv6pF4cGoEhjfaKyI6YTFCIkV6Z5X1HYl 6 | MfAQB7ZVgUX7vVVl5NmJgf0GhPYv9ORD+OZxVyigSD8SSZUq9lSHFzx/uLUJZOgW 7 | ++51ueMbV2nz5UJ83R/bGtjQyk6Vnf5fIP1wX1lXT009osJEpsM6ja0RVilzmChM 8 | kk9emiqS3ckVHYyFxFrX4iBD/LCKv0E89LWMxTx0frlv2D/4o2mK2nNBSrqOHzjx 9 | T0KjIncp8XMdAhl1tA6NtLx+m2vKcRXAYIhXABEBAAEAB/4+YSoRiU0EpUais9lY 10 | fxs30ZPBuzQBZxTyiXIcv4lEq/JIf1QmsVZDJY/Ki0ZzdIZLAsb7pYE68xwRvxi6 11 | yUvB2nTVzpYYgQY5l0T/6xQEwelxPBBN3biBFEvFMEcuqJ71UO2CUt7ucYbopPjR 12 | xn71MggKqprR8B+mDk1IMpbwX/i9m//DhROCquMVjJabtNIEpkonD1S+3LQCUuNy 13 | IRr+0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HiwTkuAwVOJLJmb42C/MTjeaNlVu 45 | 3Hf+Hm9r5KzUFhFgGeeFxTEwIse5aZ3Xy8txIP7eItyPy0QE8mhJG5rqFNVsmsks 46 | c0DKC9R8CxybANlj2UjH88rO3UTK83ZcjV0BL7avw3ILTNseO110yC0gM6IzNKsx 47 | A/4viBaWWasQ4hIlTaPeUssqW49UI6SnJACWAlvAivbIBHGodxC06CeIphv2AUbh 48 | Wi31Hk2TkN9XxlZIwA/gzs01K1vzjDDE4Utm7M/wie5ZXMDpPg3i9YalthW/fk75 49 | 5xLihnz2NkSaRRcXw9yBujF3RgVwh/qXWcMf2AR6Sagua0QAiQEfBBgBAgAJBQJV 50 | 2OssAhsMAAoJEABdjJjAVWZqmxYH/j/zA1IS30jtZmdUU4HzcpZBYCkJnMPGUjcw 51 | jnXqVloGQoTS+ndyjsAGYXexBeW0zHtBH4KSPWGMsXA9plXXXzfHiYLRbqfEBFwh 52 | 1gAuIMceTGaSbtZBGv3Tl7qgJsqSD0HCXlyQBN69trmGeCfyf0sDvYDYn0wZu/2U 53 | 6zg6twj9NkqkqxGOAM98oyhHeXD1yKcQj4+PnHMDuna1aqUN54Tga2inF36qyRKE 54 | zeO548DC81ReWPULB7ZLnUtrwQ8h4a6+pdS8thFWMU9MPsZtuyZKI/MWTaxqV+Ha 55 | 8XcSm4Z+6wR8fxGwZyD2fOQxeWjm+FSN7HUzNFwV67KHcKdLXcs= 56 | =x7UE 57 | -----END PGP PRIVATE KEY BLOCK----- 58 | -------------------------------------------------------------------------------- /test/pgp.user.public.asc: -------------------------------------------------------------------------------- 1 | -----BEGIN PGP PUBLIC KEY BLOCK----- 2 | Version: GnuPG v1 3 | 4 | mQENBFXY6ywBCADgZYPypF61Fncr96dsWgLH+u94+iTPTiOdlneYqMKz3Ti2MDE1 5 | jPj5VHwT2x1F1+g31ASrzWX1SIq63HaJv6pF4cGoEhjfaKyI6YTFCIkV6Z5X1HYl 6 | MfAQB7ZVgUX7vVVl5NmJgf0GhPY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WciYXeUBbAOCLu7ljijWo9m5wARAQABiQEfBBgBAgAJBQJV2OssAhsM 23 | AAoJEABdjJjAVWZqmxYH/j/zA1IS30jtZmdUU4HzcpZBYCkJnMPGUjcwjnXqVloG 24 | QoTS+ndyjsAGYXexBeW0zHtBH4KSPWGMsXA9plXXXzfHiYLRbqfEBFwh1gAuIMce 25 | TGaSbtZBGv3Tl7qgJsqSD0HCXlyQBN69trmGeCfyf0sDvYDYn0wZu/2U6zg6twj9 26 | NkqkqxGOAM98oyhHeXD1yKcQj4+PnHMDuna1aqUN54Tga2inF36qyRKEzeO548DC 27 | 81ReWPULB7ZLnUtrwQ8h4a6+pdS8thFWMU9MPsZtuyZKI/MWTaxqV+Ha8XcSm4Z+ 28 | 6wR8fxGwZyD2fOQxeWjm+FSN7HUzNFwV67KHcKdLXcs= 29 | =6WZE 30 | -----END PGP PUBLIC KEY BLOCK----- 31 | -------------------------------------------------------------------------------- /test/test_helper.rb: -------------------------------------------------------------------------------- 1 | # Load the Redmine helper 2 | require File.expand_path(File.dirname(__FILE__) + '/../../../test/test_helper') 3 | -------------------------------------------------------------------------------- /test/unit/pgpkey_test.rb: -------------------------------------------------------------------------------- 1 | require File.expand_path('../../test_helper', __FILE__) 2 | 3 | class PgpkeyTest < ActiveSupport::TestCase 4 | 5 | # Replace this with your real tests. 6 | def test_truth 7 | assert true 8 | end 9 | end 10 | --------------------------------------------------------------------------------