Doc-dev : Différence entre versions
De Trustedbird Client Wiki
(Page créée avec « == Versioning convention == This chapter describes best practices for managing versions of universal messaging client Trustedbird and add-ons developed. Version identifies t… ») |
(Page redirigée vers Developer Documentation) |
||
(Une révision intermédiaire par le même utilisateur non affichée) | |||
Ligne 1 : | Ligne 1 : | ||
− | == Versioning convention == |
||
+ | #REDIRECT [[Developer Documentation]] |
||
− | This chapter describes best practices for managing versions of universal messaging client Trustedbird and add-ons developed. |
||
− | |||
− | Version identifies the state of a program in its development. It is often associated with a numbering system which allows identification, and in some cases a symbolic name. The symbolic names are not used in this project. |
||
− | |||
− | |||
− | === Life cycle of a software === |
||
− | |||
− | {| class="wikitable" border="10" width="80%" align="rigth" style="background-color:#CCFFCC" |
||
− | |+ |
||
− | |- |
||
− | ! scope="col" | |
||
− | ! scope="col" | |
||
− | |- |
||
− | | width="65%" align="justify" rowspan="2" | |
||
− | <br><br><br><br> |
||
− | | width="35%" align="center" rowspan="6" | |
||
− | [[Image:milimail_versioning.png|Life cycle of a software]] |
||
− | |- |
||
− | | width="65%" align="justify" | |
||
− | |- |
||
− | | width="65%" align="justify" | |
||
− | <b>phase alpha:</b> |
||
− | * Available for an overview of the progress of the product, testing the functions currently implemented |
||
− | |- |
||
− | | width="65%" align="justify" | |
||
− | <b>phase beta:</b> |
||
− | * The set of features is usually fixed, it is a test version to reach a maximum of bugs |
||
− | |- |
||
− | | width="65%" align="justify" | |
||
− | <b>release candidate:</b> |
||
− | * Release candidate to be the final version<br><br> |
||
− | |- |
||
− | | width="60%" align="justify" | |
||
− | <b>GA version (for General Availability):</b> |
||
− | * Final version of the product. The version includes bug fixes found after the final version of the product, an upgrade may also be a new version of the product |
||
− | |} |
||
− | <br> |
||
− | |||
− | === Versioning usage === |
||
− | The version number will be as follows:<br> |
||
− | <center>'''major.minor.revision.build'''</center><br> |
||
− | Note: the number associated with the revision, can be called maintenance.<br> |
||
− | Here is how to increment the values of the version number.<br> |
||
− | <br> |
||
− | |||
− | {| class="wikitable" border="1" width="80%" align="rigth" style="background-color:#FCFCFC" |
||
− | |+ |
||
− | |- |
||
− | ! scope="col" width="8%" | |
||
− | ! scope="col" width="47%" | |
||
− | ! scope="col" width="45%" | |
||
− | |- |
||
− | | width="8%" align="center" | |
||
− | Values |
||
− | | width="47%" align="justify" | |
||
− | Why to increment |
||
− | | width="45%" align="justify" | |
||
− | When |
||
− | |- |
||
− | | width="8%" align="center" | |
||
− | major |
||
− | | width="47%" align="justify" | |
||
− | * Adding an important feature. |
||
− | * Significant change of behavior of the application. |
||
− | * Significant change in the appearance of the application. |
||
− | | width="45%" align="justify" | |
||
− | As soon as developments start. |
||
− | |- |
||
− | | width="8%" align="center" | |
||
− | minor |
||
− | | width="47%" align="justify" | |
||
− | * Adding non-critical features in the application. |
||
− | * Evolution of features without change of the existing one. |
||
− | | width="45%" align="justify" | |
||
− | As soon as developments start. |
||
− | |- |
||
− | | width="8%" align="center" | |
||
− | revision |
||
− | | width="47%" align="justify" | |
||
− | * Each delivery of bug patch (Even if there's only one correction). |
||
− | | width="45%" align="justify" | |
||
− | Depends on the delivery of the final version: |
||
− | * BEFORE : '''0''' With a tag indicating what life cycle you are (alpha, beta or rc). |
||
− | * AFTER : Each time corrections are delivered. |
||
− | |- |
||
− | | width="8%" align="center" | |
||
− | build |
||
− | | width="47%" align="justify" | |
||
− | * Delivery internal or external distribution of a product. |
||
− | | width="45%" align="justify" | |
||
− | Each time the distribution is published. For the service integration, service quality or final customer. |
||
− | |} |
||
− | |||
− | |||
− | == Git repository == |
||
− | Trustedbird sources are hosted on a Git repository. |
||
− | |||
− | * [http://adullact.net/plugins/scmgit/cgi-bin/gitweb.cgi?p=milimail/trustedbird.git;a=summary Browse Git repository] |
||
− | * Repository URL: http://adullact.net/anonscm/git/milimail/trustedbird.git |
||
− | * Repository URL (with a project account): ssh://USERNAME@scm.adullact.net/scmrepos/git/milimail/trustedbird.git |
||
− | |||
− | |||
− | The repository has 2 branches: "master" and "thunderbird". |
||
− | |||
− | * '''"master"''' branch holds Trustedbird email client patch and add-ons. |
||
− | * '''"thunderbird"''' branch holds all the files from official Thunderbird sources which have been modified in "master" branch. This branch is used for [[#Upgrading_Thunderbird|upgrading Thunderbird]] when a new upstream release is available. |
||
− | |||
− | |||
− | == Build Documentation == |
||
− | === Dependencies === |
||
− | ==== Linux (Debian) ==== |
||
− | * build-essential |
||
− | * ant |
||
− | * git-core |
||
− | * libgtk2.0-dev |
||
− | * libglib1.2-dev |
||
− | * libidl-dev |
||
− | * libxt-dev |
||
− | * zip |
||
− | * unzip |
||
− | * flex |
||
− | * bison |
||
− | * fakeroot |
||
− | * dpkg-dev |
||
− | * python-dev |
||
− | * autoconf |
||
− | * libtool |
||
− | * a Java JDK for Ant (java-gcj-compat-dev, sun-java6-jdk, openjdk-6-jdk,...) |
||
− | |||
− | ==== Windows ==== |
||
− | * Microsoft Visual C++ 6 with Service Pack 5 (not Service Pack 6 because Processor Pack needs SP5) |
||
− | * Visual C++ 6.0 Processor Pack |
||
− | * Latest MozillaBuild |
||
− | * Git |
||
− | * Java JDK |
||
− | * Ant |
||
− | |||
− | |||
− | See http://developer.mozilla.org/en/docs/Windows_Build_Prerequisites for more info. |
||
− | |||
− | |||
− | * Add Ant and JDK path to the PATH variable in c:\mozilla-build\start-msvc6.bat: |
||
− | SET PATH=%PATH%;%MOZ_TOOLS%\bin;C:\mozilla-build\apache-ant-1.8.0RC1-bin\bin;C:\Program Files\Java\jdk1.6.0_18\bin |
||
− | * Set JAVA_HOME as environment variable |
||
− | |||
− | * Launch build environment with c:\mozilla-build\start-msvc6.bat |
||
− | |||
− | |||
− | === Cloning the repository === |
||
− | ==== Read only (with HTTP/HTTPS) ==== |
||
− | ~$ git clone http://adullact.net/anonscm/git/milimail/trustedbird.git |
||
− | |||
− | |||
− | ==== Read-write (with SSH) ==== |
||
− | ~$ git clone ssh://USERNAME@scm.adullact.net/scmrepos/git/milimail/trustedbird.git |
||
− | (replace USERNAME with your Adullact SSH username) |
||
− | |||
− | |||
− | === Building === |
||
− | ~$ cd trustedbird/packager |
||
− | ~/trustedbird/packager$ cd trustedbird/packager |
||
− | |||
− | |||
− | Download Thunderbird source file: |
||
− | ~/trustedbird/packager$ wget ftp://ftp.mozilla.org/pub/thunderbird/releases/2.0.0.24/source/thunderbird-2.0.0.24-source.tar.bz2 |
||
− | |||
− | |||
− | Build and package Trustedbird and all add-ons: |
||
− | ~/trustedbird/packager$ ant build-all |
||
− | |||
− | |||
− | OR: build and package only Trustedbird email client: |
||
− | ~/trustedbird/packager$ ant trustedbird |
||
− | |||
− | |||
− | OR: build and package only add-ons: |
||
− | ~/trustedbird/packager$ ant package-addons |
||
− | |||
− | |||
− | * All built packages will be available in '''trustedbird/packager/dist/''' |
||
− | |||
− | |||
− | == Upgrading Thunderbird == |
||
− | When a new upstream release of Thunderbird is available, we need to merge the changes into Trustedbird. |
||
− | |||
− | In order to do so, a special Git branch ("thunderbird") is available. |
||
− | It contains all files from official Thunderbird sources which have been modified in "master" branch for Trustedbird. |
||
− | |||
− | '''Note:''' current branch will be printed inside parentheses in the following examples. |
||
− | |||
− | |||
− | In order to do the merge of a new Thunderbird release, we'll need to have this "thunderbird" branch in our local Git repository. |
||
− | |||
− | |||
− | Extract new Thunderbird release into a directory (extracted files will be in ~/mozilla): |
||
− | ~$ tar xvfj thunderbird-2.0.0.24-source.tar.bz2 -C ~ |
||
− | |||
− | |||
− | Create a "thunderbird" local branch which tracks the remote branch named "thunderbird": |
||
− | ~$ cd trustedbird |
||
− | ~/trustedbird (master)$ git branch thunderbird origin/thunderbird |
||
− | ~/trustedbird (master)$ git branch -a |
||
− | * master |
||
− | thunderbird |
||
− | remotes/origin/HEAD -> origin/master |
||
− | remotes/origin/master |
||
− | remotes/origin/thunderbird |
||
− | |||
− | ~/trustedbird (master)$ |
||
− | |||
− | |||
− | Switch to "thunderbird" branch: |
||
− | ~/trustedbird (master)$ git checkout thunderbird |
||
− | ~/trustedbird (thunderbird)$ |
||
− | ~/trustedbird (thunderbird)$ cd trustedbird-patch-source-2/ |
||
− | ~/trustedbird/trustedbird-patch-source-2 (thunderbird)$ |
||
− | |||
− | |||
− | Update files with new versions: |
||
− | ~/trustedbird/trustedbird-patch-source-2 (thunderbird)$ find -type f -exec cp ~/mozilla/{} {} \; |
||
− | |||
− | |||
− | Commit changes (if any): |
||
− | ~/trustedbird/trustedbird-patch-source-2 (thunderbird)$ git commit -va |
||
− | |||
− | |||
− | Switch back to "master" branch: |
||
− | ~/trustedbird/trustedbird-patch-source-2 (thunderbird)$ git checkout master |
||
− | ~/trustedbird/trustedbird-patch-source-2 (master)$ |
||
− | |||
− | |||
− | Merge "thunderbird" branch into "master" branch: |
||
− | ~/trustedbird/trustedbird-patch-source-2 (master)$ git merge thunderbird |
||
− | |||
− | |||
− | Resolve conflicts (if any) and commit: |
||
− | ~/trustedbird/trustedbird-patch-source-2 (master)$ git commit -va |
||
− | |||
− | == How to build a localized Thunderbird 2 == |
||
− | See [[Build Localized Thunderbird]]. |
||
− | |||
− | == SSL certificates generation == |
||
− | In order to sign and encrypt messages, you'll need to have certificates. |
||
− | |||
− | Certificates can be generated with a Perl script CA.pl supplied with openssl. |
||
− | |||
− | *1) Create a certificate hierarchy in new directory demoCA/ |
||
− | $ /usr/lib/ssl/misc/CA.pl -newca |
||
− | ''(type enter when prompted to create a new certificate and fill at least "Common Name" field)'' |
||
− | |||
− | :=> '''demoCA/cacert.pem''': root certificate (CA) |
||
− | |||
− | *2) Create a new certificate request for a user |
||
− | $ /usr/lib/ssl/misc/CA.pl -newreq |
||
− | :=> '''newkey.pem''': user's private key |
||
− | :=> '''newreq.pem''': certificate request for the user |
||
− | |||
− | *3) Sign the certificate request with certificate authority key |
||
− | $ /usr/lib/ssl/misc/CA.pl -signreq |
||
− | :=> '''newcert.pem''': user's signed certificate |
||
− | |||
− | *4) Convert certificate to DER format (for LDAP) |
||
− | $ openssl x509 -outform DER -in newcert.pem -out newcert.der |
||
− | :=> '''newcert.der''': user's signed certificate in DER format |
||
− | |||
− | *5) Create PKCS#12 |
||
− | $ /usr/lib/ssl/misc/CA.pl -pkcs12 "Name of the certificate" |
||
− | :=> '''newcert.p12''': root certificate, user's signed certificate and user's private key |
||
− | |||
− | *6) Revoke a certificate |
||
− | $ openssl ca -revoke newcert.pem |
||
− | $ openssl ca -gencrl -out crl.pem |
||
− | $ openssl crl -inform PEM -outform DER -in crl.pem -out crl.der |
||
− | :=> '''crl.pem'''/'''crl.der''': certificate revocation list |
||
− | |||
− | |||
− | === Import a user's certificate into Thunderbird === |
||
− | Import newcert.p12 in "Your certificates" tab in Thunderbird certificate manager. |
||
− | |||
− | In "Authorities" tab in Thunderbird certificate manager, choose to trust the CA of the certificate to identify email users. |
||
− | |||
− | (do again step #2 to #5 to create a new certificate for another user issued by the same authority) |
||
− | |||
− | == Manipulate DER/ASN1 == |
||
− | Decode Base64 -> DER-encoded: |
||
− | $ openssl base64 -d -in message.b64 -out message.der |
||
− | |||
− | View DER-encoded in human-readable text: |
||
− | $ dumpasn1 message.der |
||
− | OR |
||
− | $ openssl asn1parse -in message.der -inform DER -i -dump |
||
− | |||
− | Decrypt DER-encoded with private key: |
||
− | $ openssl smime -decrypt -in message.der -inform DER -inkey private.key.pem -out message.clear |
||
− | |||
− | == Other technical documentation == |
||
− | |||
− | [{{SERVER}}{{SCRIPTPATH}}/documents/MILIMAIL_Specifications_Techniques_v020.pdf Functional and technical specifications (French version)] |
||
− | |||
− | [{{SERVER}}{{SCRIPTPATH}}/documents/normes_prog_milimail.pdf Standards of development (French version)] |
||
− | |||
− | [{{SERVER}}{{SCRIPTPATH}}/documents/Recommandation_format_XSMTP_V11.pdf XSMTP Recommandations (French version)] |
Version actuelle en date du 9 septembre 2010 à 16:00
Rediriger vers :