--- a/ssm-en.xhtml Sun Aug 21 21:27:40 2016 +0200
+++ b/ssm-en.xhtml Sun Aug 21 23:50:40 2016 +0200
@@ -8,160 +8,221 @@
<body>
<h1>Sane Software Manifesto</h1>
-
<p>In respect to user freedoms, privacy, liberty, quality, mental health and world peace we create software according to these guidelines.</p>
-
- <h2>free software</h2>
+ <h2>Free software</h2>
- user has freedoms
- user controls his/her computer and software
- non-free software can not be trusted
- must be buildable using free software toolchain (like GNU/Linux + GNU GCC or OpenJDK etc.)
- should not promote non-free (proprietary) software or services
- copyleft licenses (like GNU GPL or GNU Affero GPL) are recommended because they guarantee software freedoms to every single end-user and prevent possibility that freedom vanishes somewhere in the distribution chain a user can't benefit from the free software albeit the software is build on originally free source code
+ <ul>
+ <li>user has freedoms</li>
+ <li>user controls his/her computer and software and owns the data</li>
+ <li>non-free software can not be trusted </li>
+ <li>must be buildable using free software toolchain (like GNU/Linux + GCC or OpenJDK etc.)</li>
+ <li>should not promote non-free (proprietary) software or services</li>
+ <li>copyleft licenses (like GNU GPL or GNU Affero GPL) are recommended because they guarantee software freedoms to every single end-user and prevent possibility that freedom vanishes somewhere in the distribution chain and the user can't benefit from the free software albeit the software is build on originally free source code</li>
+ </ul>
- <h2>documented</h2>
- at least basic documentation must be released under a free license (GNU FDL is recommended)
- there might be also other documentation/books released under any license and price
- but average software engineer must be able to build and operate the software with just basic free documentation
- there must be a free documentation describing building and running of the software on a fresh operating system installation including description of all dependencies
- documentation should focus on all target groups: users, administrators, developers
- there must be a big picture and software architercure described
+ <h2>Documented</h2>
+ <ul>
+ <li>at least basic documentation must be released under a free license (GNU FDL is recommended)</li>
+ <li>there might be also other documentation/books released under any license and price</li>
+ <li>but average software engineer must be able to build and operate the software with just the basic free documentation</li>
+ <li>there must be a free documentation describing building and running of the software on a fresh operating system installation including description of all dependencies</li>
+ <li>documentation should focus on all target groups: users, administrators, developers</li>
+ <li>there must be a big picture and software architercure described</li>
+ </ul>
- <h2>semantic versioning</h2>
- strongly recommended
- required when the package is suposed to be used as dependency by others
- if there is need of some marketing or cool versioning/codenames like Ultrasonic Umbrella or 2016, they should be used in addition to semantic versioning, not instead it
- once publicly released, the package must not be changed anymore – if a change (even small fix) is needed, new version number must be assigned
- APIs, file formats and protocols might be semanticly versioned independently from the implementation
- in such case, there should be a table documenting which API/format/protocol version matches which implementation version
+ <h2>Semantic versioning</h2>
+ <ul>
+ <li>strongly recommended</li>
+ <li>required when the package is suposed to be used as dependency by others</li>
+ <li>if there is need of some marketing or cool versioning/codenames like Ultrasonic Umbrella or 2016, they should be used in addition to semantic versioning, not instead it</li>
+ <li>once publicly released, the package must not be changed anymore – if a change (even small fix) is needed, new version number must be assigned</li>
+ <li>
+ APIs, file formats and protocols might be semanticly versioned independently from the implementation;
+ in such case, there should be a table documenting which API/format/protocol version matches which implementation version
+ </li>
+ </ul>
- <h2>compatibilible with itself</h2>
- focus on backward compatibility
- don't broke things
- incompatible changes must be planned and announced in advance
- upgrade scripts + upgrade documentation
+ <h2>Compatibilible with itself</h2>
+ <ul>
+ <li>focus on backward compatibility</li>
+ <li>don't broke things</li>
+ <li>incompatible changes must be planned and announced in advance</li>
+ <li>upgrade scripts + upgrade documentation</li>
+ </ul>
- <h2>compatibilible with others</h2>
- use open standards (protocols, formats) if they exist
- define own open standards if needed
- also standards must be semantically versioned
- should be written in machine readable format (WSDL, WADL, ASN.1, XSD, Diameter dictionary etc.) or at least formal language (Backus–Naur Form, EBNF etc.)
- also configuration should have machine readable description and should be testable by executing a command
+ <h2>Compatibilible with others</h2>
+ <ul>
+ <li>use open standards (protocols, formats) if they exist</li>
+ <li>define own open standards if needed
+ <ul>
+ <li>also standards must be semantically versioned</li>
+ <li>should be written in machine readable format (WSDL, WADL, ASN.1, XSD, Diameter dictionary etc.) or at least formal language (Backus–Naur Form, EBNF etc.)</li>
+ <li>also configuration should have machine readable description and should be testable by executing a command</li>
+ </ul>
+ </li>
+ </ul>
- <h2>modular architecture</h2>
- larger and multi-purpose software should be divided into smaller modules
- modules must have defined dependencies (less = better)
- particular modules should be compilable and executable separately
- whole system should be compilable with only selected modules – must not require compilation or even distribution of all modules, if they are not necessary
+ <h2>Modular architecture</h2>
+ <ul>
+ <li>larger and multi-purpose software should be divided into smaller modules</li>
+ <li>modules must have defined dependencies (less = better)</li>
+ <li>particular modules should be compilable and executable separately</li>
+ <li>whole system should be compilable (buildable) with only selected modules – must not require compilation or even distribution of all modules, if they are not necessary</li>
+ </ul>
+
+ <h2>Extensible</h2>
- <h2>extensible</h2>
- able to be extended
- by configuration (RegExp, SQL, XSLT, XPath etc.)
- by scripting (Guile, ECMA Script etc.)
- and/or third-party plugins/modules
- it should be easy to create a third-party module and plug it in an existing system
- dependencies needed to write an extension (i.e. header files, API classes/interfaces) should be as small as possible (do not require large codebase to write an extension)
- there should be public directory of extensions/scripts
+ <ul>
+ <li>able to be extended
+ <ul>
+ <li>by configuration (RegExp, SQL, XSLT, XPath etc.)</li>
+ <li>by scripting (Guile, Bash, ECMA Script etc.)</li>
+ <li>and/or third-party plugins/modules
+ <ul>
+ <li>it should be easy to create a third-party module and plug it in an existing system</li>
+ <li>dependencies needed to write an extension (i.e. header files, API classes/interfaces) should be as small as possible (do not require large codebase to write a mere plug-in)</li>
+ </ul>
+ </li>
+ </ul>
+ </li>
+ <li>there should be public directory of extensions/scripts</li>
+ </ul>
- <h2>testable</h2>
- there should be automated build-time complex tests for the package – feed the program with sample input and verify expected output
- there should be also automated runtime/postinstall tests – in order to verify that software was installed properly, all required dependencies are met and basic function is guaranteed – the program should report problem during its start (as a warning if it is not fatal), instead of unexpected failures during operation
- unit tests are recommended for code parts that are internally complex (algorithms, important business logic) and have simple interfaces
+ <h2>Testable</h2>
+ <ul>
+ <li>there should be automated build-time complex tests for the package – feed the program with sample input and verify expected output</li>
+ <li>there should be also automated runtime/postinstall tests – in order to verify that software was installed properly, all required dependencies are met and basic function is guaranteed – the program should report problem during its start (as a warning if it is not fatal), instead of unexpected failures during operation</li>
+ <li>unit tests are recommended for code parts that are internally complex (algorithms, important business logic) and have simple interfaces</li>
+ </ul>
- <h2>safe code and sustainability</h2>
- correctness, safety and readability is prefered to performance
- use strong data typing, declare preconditions and possible exceptions
- data structures must be known and well documented – don't use undocumented map keys or properties
- code, comments and analysis should be written in the same natural language
- there should be a dictionary of used terms, so whole team and also users and customers will speak same language
+ <h2>Safe code and sustainability</h2>
+ <ul>
+ <li>correctness, safety and readability is prefered to performance</li>
+ <li>use strong data typing, declare preconditions and possible exceptions</li>
+ <li>data structures must be known and well documented – don't use undocumented map keys or properties</li>
+ <li>code, comments and analysis should be written in the same natural language</li>
+ <li>there should be a dictionary of used terms, so whole team and also users and customers will speak same language</li>
+ </ul>
- <h2>small code footprint</h2>
- less LOC (resp. complexity) = better
- reduce boilerplate and unused code
- use code generators (during build process, not to generate code to be manually edited and versioned)
+ <h2>Small code footprint</h2>
+ <ul>
+ <li>less LOC (resp. complexity) = better</li>
+ <li>reduce boilerplate and unused code</li>
+ <li>use code generators (during build process, not to generate code to be manually edited and versioned)</li>
+ </ul>
- <h2>sane dependencies</h2>
- avoid NIH and reuse code but also avoid dependency hell
- know your dependencies, know why they are required
- reduce dependencies to only necessary ones
- depend on small and useful libraries – not on bulky application packages
- if dependency on bulky application package is inevitable, add a layer of abstraction – create a generic interface and connector and allow others to replace the bulky package with their own sane implementation
- helper tools:
- if you e.g. use Bash and Perl during the build process, don't add also Python dependency, write it in Perl – or use Python instead of Perl.
- Or if you use Java as your main language, consider not using Python/Perl for scripting and use Java for it
- if possible, always depend on abstract interfaces, not on particular implementations
+ <h2>Sane dependencies</h2>
+ <ul>
+ <li>avoid NIH and reuse code but also avoid dependency hell</li>
+ <li>know your dependencies, know why they are required</li>
+ <li>reduce dependencies to only necessary ones</li>
+ <li>depend on small and useful libraries – not on bulky application packages</li>
+ <li>if dependency on bulky application package is inevitable, add a layer of abstraction – create a generic interface and connector and allow others to replace the bulky package with their own sane implementation</li>
+ <li>helper tools:
+ <ul>
+ <li>if you e.g. use Bash and Perl during the build process, don't add also Python dependency, write it in Perl – or use Python instead of Perl.</li>
+ <li>Or if you use Java as your main language, consider not using Python/Perl for scripting and use Java for it</li>
+ </ul>
+ </li>
+ <li>if possible, always depend on abstract interfaces, not on particular implementations</li>
+ </ul>
- <h2>easily auditable</h2>
- small code footprint and minimal dependencies makes it easy to do security audit
- avoid ungrounded refactoring and reformatting – they make mess and noise in the version control system and impede the audit
- refactoring/reformatting changesets should be separated from substantive changes
+ <h2>Easily auditable</h2>
+ <ul>
+ <li>small code footprint and minimal dependencies makes it easy to do security audit</li>
+ <li>avoid ungrounded refactoring and reformatting – they make mess and noise in the version control system and impede the audit</li>
+ <li>refactoring/reformatting changesets should be separated from substantive changes</li>
+ </ul>
- <h2>reproducible builds</h2>
- builds should be reproducible: same code/version → same binary package
- if not, it should be documented, why and how build products mihgt differ, and there should be plan/task to make it reproducible
+ <h2>Reproducible builds</h2>
+ <ul>
+ <li>builds should be reproducible: same code/version → same binary package</li>
+ <li>if not, it should be documented, why and how build products mihgt differ, and there should be plan/task to make it reproducible</li>
+ </ul>
- <h2>trustworthy packages and sources</h2>
- every released version (binary or source) is cryptographically signed by the authors (GnuPG/OpenPGP is strongly recommended)
- if HTTP is supported, HTTPS should also be – the attacker/eavesdropper should not even know what software/package/update is downloaded by the user
- the attacker should not be able to suppress updates – the program must not be silent in such case and must warn the user that something possibly nasty and dangerous is happening
- releases should be downloadable also (or exclusively) over BitTorrent or other P2P network
- there should be also checksums/hashes for every package
- source code repository is accessible through an encrypted connection
+ <h2>Trustworthy packages and sources</h2>
+ <ul>
+ <li>every released version (binary or source) is cryptographically signed by the authors (GnuPG/OpenPGP is strongly recommended)</li>
+ <li>if HTTP is supported, HTTPS should also be – the attacker/eavesdropper should not even know what software/package/update is downloaded by the user</li>
+ <li>the attacker should not be able to suppress updates – the program must not be silent in such case and must warn the user that something possibly nasty and dangerous is happening </li>
+ <li>releases should be downloadable also (or exclusively) over BitTorrent or other P2P network</li>
+ <li>there should be also checksums/hashes for every package</li>
+ <li>source code repository is accessible through an encrypted connection</li>
+ </ul>
- <h2>network interactions</h2>
- no network connection is needed during build – build must be possible completely offline, all dependencies must be downloadable and documented including secure hashes or better cryptographic signatures
- if dependencies are optionally automatically downloaded during/before build, the packaging system must cryptographically verify that that they are undamaged
- avoid unwanted network interactions during runtime – no „call home“ or update-checks without user's explicit consent
- if any network connection is used, it must be cryptographically secured against MITM attacks
+ <h2>Network interactions</h2>
+ <ul>
+ <li>no network connection is needed during build – build must be possible completely offline, all dependencies must be downloadable and documented including secure hashes or better cryptographic signatures</li>
+ <li>if dependencies are optionally automatically downloaded during/before build, the packaging system must cryptographically verify that that they are undamaged</li>
+ <li>avoid unwanted network interactions during runtime – no „call home“ or update-checks without user's explicit consent</li>
+ <li>if any network connection is used, it must be cryptographically secured against MITM attacks</li>
+ </ul>
- <h2>localized/internationalized</h2>
- is is strongly recommended that it should be possible to localize the user interface independently from the original author by writing a language pack
- GNU Gettext or other standard framework (like Java resource bundles) should be used
- error messages should have assigned unique error codes, so it is possible to find relevant information regardless current locale
- GEC is recommended for such unique error identifiers
- data formats and protocols must be language/locale independent
- e.g. use decimal point instead of comma and no thousand separators for numbers, use standardized date formats
- in general: everything that is expected to be machine-readable or machine-generated must be independent from current locale
- character encoding:
- always be aware of it, don't just blindly use current platform's default (because the other side might run on different platform with different default)
- if given software/format/protocol has some default encoding, it must be clearly defined in its specification and this default should not be changed without changing the major version number
- if there is no default, the encoding must be specified in the metadata attached (e.g. protocol headers, extended attributes on filesystem) to the actual data or at least at the begining of the data (like declaration in XML format)
- the metric system should be used as default
+ <h2>Localized/internationalized</h2>
+ <ul>
+ <li>is is strongly recommended that it should be possible to localize the user interface independently from the original author by writing a language pack</li>
+ <li>GNU Gettext or other standard framework (like Java resource bundles) should be used</li>
+ <li>error messages should have assigned unique error codes, so it is possible to find relevant information regardless current locale</li>
+ <!-- GEC is recommended for such unique error identifiers -->
+ <li>data formats and protocols must be language/locale independent
+ <ul>
+ <li>e.g. use decimal point instead of comma and no thousand separators for numbers, use standardized date formats</li>
+ <li>in general: everything that is expected to be machine-readable or machine-generated must be independent from current locale</li>
+ </ul>
+ </li>
+ <li>character encoding:
+ <ul>
+ <li>always be aware of it, don't just blindly use current platform's default (because the other side might run on different platform with different default)</li>
+ <li>if given software/format/protocol has some default encoding, it must be clearly defined in its specification and this default should not be changed without changing the major version number</li>
+ <li>if there is no default, the encoding must be specified in the metadata attached (e.g. protocol headers, extended attributes on filesystem) to the actual data or at least at the begining of the data (like declaration in XML format)</li>
+ </ul>
+ </li>
+ <li>the metric system should be used as default</li>
+ </ul>
- <h2>communication channels</h2>
- RSS/Atom or other machine readable format for:
- security announcements
- new version announcements
- infrastructure outage announcements
- blog, documentation, how-tos etc.
- AFK events (conferences, meetings, hackatons etc.), for calendar data iCal format is strongly recommended
- mailing list
- e-mail/smtp
- use TLS
- use DKIM/ADSP
- use signed and encrypted messages (GnuPG or X.509)
- avoid spam and viruses, don't spam the users, don't push them to subscribe your „newsletter“ – always offer also anonymous channel like RSS/Atom
- Jabber MUC or IRC
- discussion forum
- don't push users to register at a proprietary social networks resp. at particular company like Facebook – users without such account must not be discriminated – use open and decentralized networks/protocols instead
- Q&A tool + FAQ
- there should be a second-level internet domain for the project or its team
- but don't buy an internet domain if you are not prepared to mainain it for decades – rather use third level domain under some reliable second level domain maintained by a credible group or person – think of that every expired domain helps spammers and scammers and hurts the users
- URLs should be as stable as possible (don't broke old links, set up redirections if needed)
- the website must be independent and must contain everything needed – any content (JavaScripts, CSS, fonts etc.) downloaded from othed domains must not be required to browse/use the website
- authors should publish their public keys (GnuPG/OpenPGP or X.509)
- crpyptographically secured e-mail address or web form for receiving security vulnerabilities report
- every security incident must be clearly documented and investigated – don't obscure it
+ <h2>Communication channels</h2>
+ <ul>
+ <li>use RSS/Atom or other machine readable format for:
+ <ul>
+ <li>security announcements</li>
+ <li>new version announcements</li>
+ <li>infrastructure outage announcements</li>
+ <li>blog, documentation, how-tos etc.</li>
+ <li>AFK events (conferences, meetings, hackatons etc.), for calendar data iCal format is strongly recommended</li>
+ </ul>
+ </li>
+ <li>mailing list</li>
+ <li>e-mail/SMTP
+ <ul>
+ <li>use TLS</li>
+ <li>use DKIM/ADSP</li>
+ <li>use signed and encrypted messages (GnuPG or X.509)</li>
+ <li>avoid spam and viruses, don't spam the users, don't push them to subscribe your „newsletter“ – always offer also anonymous channel like RSS/Atom</li>
+ </ul>
+ </li>
+ <li>Jabber MUC or IRC</li>
+ <li>discussion forum</li>
+ <li>don't push users to register at a proprietary social networks resp. at particular company like Facebook – users without such account must not be discriminated – use open and decentralized networks/protocols instead</li>
+ <li>Q&A tool + FAQ</li>
+ <li>there should be a second-level internet domain for the project or its team</li>
+ <li>but don't buy an internet domain if you are not prepared to mainain it for decades – rather use third level domain under some reliable second level domain maintained by a credible group or person – think of that every expired domain helps spammers and scammers and hurts the users</li>
+ <li>URLs should be as stable as possible (don't broke old links, set up redirections if needed)</li>
+ <li>the website must be independent and must contain everything needed – any content (JavaScripts, CSS, fonts, images etc.) downloaded from other domains must not be required to browse/use the website</li>
+ <li>authors should publish their public keys (GnuPG/OpenPGP or X.509)</li>
+ <li>crpyptographically secured e-mail address or web form for receiving security vulnerabilities report</li>
+ <li>every security incident must be clearly documented and investigated – don't obscure it</li>
+ </ul>
- <h2>open development – has public:</h2>
- source code repository (versioning system), not just source code releases
- description of the process of accepting external patches
- feature/bug tracking system
- roadmap of future releases
- plan of supported versions/branches
- every release/version/branch must clearly declare the status (alpha, beta, prototype, stable, retired, deprecated…)
+ <h2>Open development – has public:</h2>
+ <ul>
+ <li>source code repository (versioning system), not just source code releases</li>
+ <li>description of the process of accepting external patches</li>
+ <li>feature/bug tracking system</li>
+ <li>roadmap of future releases</li>
+ <li>plan of supported versions/branches</li>
+ <li>every release/version/branch must clearly declare the status (alpha, beta, prototype, stable, retired, deprecated…)</li>
+ </ul>
</body>