Benjamin Kaduk | e4d9426 | 2016-09-26 15:30:42 -0500 | [diff] [blame] | 1 | HOW TO CONTRIBUTE PATCHES TO OpenSSL |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 2 | ------------------------------------ |
Manish Goregaokar | eb05f17 | 2015-10-17 16:40:55 +0530 | [diff] [blame] | 3 | |
Matt Caswell | 75737d4 | 2016-06-02 11:03:10 +0100 | [diff] [blame] | 4 | (Please visit https://www.openssl.org/community/getting-started.html for |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 5 | other ideas about how to contribute.) |
Manish Goregaokar | eb05f17 | 2015-10-17 16:40:55 +0530 | [diff] [blame] | 6 | |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 7 | Development is coordinated on the openssl-dev mailing list (see the |
Matt Caswell | 75737d4 | 2016-06-02 11:03:10 +0100 | [diff] [blame] | 8 | above link or https://mta.openssl.org for information on subscribing). |
Manish Goregaokar | eb05f17 | 2015-10-17 16:40:55 +0530 | [diff] [blame] | 9 | If you are unsure as to whether a feature will be useful for the general |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 10 | OpenSSL community you might want to discuss it on the openssl-dev mailing |
| 11 | list first. Someone may be already working on the same thing or there |
| 12 | may be a good reason as to why that feature isn't implemented. |
Manish Goregaokar | eb05f17 | 2015-10-17 16:40:55 +0530 | [diff] [blame] | 13 | |
Rich Salz | 7954dce | 2016-10-12 15:49:06 -0400 | [diff] [blame] | 14 | To submit a patch, make a pull request on GitHub. If you think the patch |
| 15 | could use feedback from the community, please start a thread on openssl-dev |
| 16 | to discuss it. |
Manish Goregaokar | eb05f17 | 2015-10-17 16:40:55 +0530 | [diff] [blame] | 17 | |
Rich Salz | 7954dce | 2016-10-12 15:49:06 -0400 | [diff] [blame] | 18 | Having addressed the following items before the PR will help make the |
| 19 | acceptance and review process faster: |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 20 | |
| 21 | 1. Anything other than trivial contributions will require a contributor |
| 22 | licensing agreement, giving us permission to use your code. See |
Matt Caswell | 75737d4 | 2016-06-02 11:03:10 +0100 | [diff] [blame] | 23 | https://www.openssl.org/policies/cla.html for details. |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 24 | |
| 25 | 2. All source files should start with the following text (with |
| 26 | appropriate comment characters at the start of each line and the |
| 27 | year(s) updated): |
| 28 | |
| 29 | Copyright 20xx-20yy The OpenSSL Project Authors. All Rights Reserved. |
| 30 | |
| 31 | Licensed under the OpenSSL license (the "License"). You may not use |
| 32 | this file except in compliance with the License. You can obtain a copy |
| 33 | in the file LICENSE in the source distribution or at |
| 34 | https://www.openssl.org/source/license.html |
| 35 | |
Rich Salz | 7954dce | 2016-10-12 15:49:06 -0400 | [diff] [blame] | 36 | 3. Patches should be as current as possible; expect to have to rebase |
| 37 | often. We do not accept merge commits; You will be asked to remove |
| 38 | them before a patch is considered acceptable. |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 39 | |
Matt Caswell | 75737d4 | 2016-06-02 11:03:10 +0100 | [diff] [blame] | 40 | 4. Patches should follow our coding style (see |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 41 | https://www.openssl.org/policies/codingstyle.html) and compile without |
FdaSilvaYY | f430ba3 | 2016-06-19 19:39:01 +0200 | [diff] [blame] | 42 | warnings. Where gcc or clang is available you should use the |
Matt Caswell | 75737d4 | 2016-06-02 11:03:10 +0100 | [diff] [blame] | 43 | --strict-warnings Configure option. OpenSSL compiles on many varied |
| 44 | platforms: try to ensure you only use portable features. |
Rich Salz | 7954dce | 2016-10-12 15:49:06 -0400 | [diff] [blame] | 45 | Clean builds via Travis and AppVeyor are expected, and done whenever |
| 46 | a PR is created or updated. |
Rich Salz | f2b9c25 | 2016-04-26 15:50:28 -0400 | [diff] [blame] | 47 | |
Rich Salz | 7954dce | 2016-10-12 15:49:06 -0400 | [diff] [blame] | 48 | 5. When at all possible, patches should include tests. These can |
| 49 | either be added to an existing test, or completely new. Please see |
| 50 | test/README for information on the test framework. |
Matt Caswell | 49c2a00 | 2016-06-03 10:51:13 +0100 | [diff] [blame] | 51 | |
Rich Salz | 7954dce | 2016-10-12 15:49:06 -0400 | [diff] [blame] | 52 | 6. New features or changed functionality must include |
Beat Bolli | 663ece0 | 2016-11-18 10:17:28 +0100 | [diff] [blame] | 53 | documentation. Please look at the "pod" files in doc/man[1357] |
| 54 | for examples of our style. |