branch merge
authorTomas Zeman <tzeman@volny.cz>
Mon, 21 Jan 2013 10:13:02 +0100
changeset 29 f76e13e69c95
parent 28 4beaaa539ed9 (current diff)
parent 27 cac4d69d8821 (diff)
child 30 14d669d74b48
branch merge
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/coffeescript/frameworks	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,12 @@
+http://zappajs.org/
+
+Zappa is a CoffeeScript DSL-ish interface for building web apps on the node.js
+runtime, integrating express, socket.io and other best-of-breed libraries.
+
+https://github.com/tcr/rem-js
+
+REM is a REST library that does away with excessive configuration, confusing
+authentication, and incomplete libraries. Whether using an existing API or
+writing your own, REM is the fewest lines of code between reading documentation
+and getting started. And with support for popular services built-in, you might
+never need another web service library.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/freebsd/openvpn	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,17 @@
+http://www.freebsddiary.org/openvpn.php
+The solution here is rather simplistic. It allows for a single client to
+connect to a single server. You cannot do multiple clients with this setup.
+
+
+http://www.freebsddiary.org/openvpn-easy-rsa.php
+The FreeBSD Port for OpenVPN installs "a small RSA key management package based
+on the openssl command line tool". This package is provided by the OpenVPN
+project and can be found at /usr/local/share/doc/openvpn/easy-rsa/. 
+
+
+http://www.freebsddiary.org/openvpn-routed.php
+In this article, I will show you how I created a routed VPN using OpenVPN. In
+this network, multiple clients can attach to the server, each of which has
+access to the network attached to the server. Each client can also contact any
+other client, subject to firewall rules. 
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/freebsd/portsnap-hg/hgignore	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,6 @@
+syntax: glob
+*~
+.*.swp
+INDEX*
+distfiles
+packages
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/freebsd/portsnap-hg/howto	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,29 @@
+Howto import ports (updated by portsnap) into mercurial repo:
+
+(assumed under user portsnap with homedir /portsnap)
+
+  * Repository:
+
+hg init ~/ports
+hg add .hgignore #see hgignore file
+
+  * Portsnap conf:
+
+~/.portsnaprc #see portsnaprc
+
+  * Initial import:
+
+PS="portsnap -f /portsnap/.portsnaprc"
+PSDIR=/portsnap/ports
+$PS fetch
+$PS extract
+cd $PSDIR && hg addremove && hg ci ...
+
+  * Regular updates (crontab):
+
+PATH=/bin:/usr/bin:/usr/local/bin:/usr/sbin
+PSDIR=/portsnap/ports
+PS="portsnap -f /portsnap/.portsnaprc"
+PSLOG=/portsnap/log/portsnap.log
+13 */6  * * *   cd $PSDIR && $PS cron && $PS update && hg addremove && hg ci -m 'Update' >> $PSLOG
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/freebsd/portsnap-hg/portsnaprc	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,18 @@
+# Default directory where compressed snapshots are stored.
+WORKDIR=/portsnap/var/db/portsnap
+
+# Default location of the ports tree (target for "update" and "extract").
+PORTSDIR=/portsnap/ports
+
+SERVERNAME=portsnap.FreeBSD.org
+
+# Trusted keyprint.  Changing this is a Bad Idea unless you've received
+# a PGP-signed email from <security-officer@FreeBSD.org> telling you to
+# change it and explaining why.
+KEYPRINT=9b5feee6d69f170e3dd0a2c8e469ddbd64f13f978f2f3aede40c98633216c330
+
+# List of INDEX files to build and the DESCRIBE file to use for each
+INDEX INDEX-6 DESCRIBE.6
+INDEX INDEX-7 DESCRIBE.7
+INDEX INDEX-8 DESCRIBE.8
+
--- a/icons/free-icons	Fri Sep 02 17:01:42 2011 +0200
+++ b/icons/free-icons	Mon Jan 21 10:13:02 2013 +0100
@@ -8,3 +8,5 @@
 famfamfam.com
 icojoy.com
 techlogica.us
+
+http://www.designdownloader.com/
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/java/keytool	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,11 @@
+http://community.jboss.org/wiki/GeneratingSelfSignedCertificateWithKeytool
+Generating Self Signed Certificate with Keytool
+
+Creating private/public key pair:
+keytool -genkey -alias ... -keyalg RSA -validity 365 -keystore server.keystore -storetype JKS
+
+Extracting the public key:
+keytool -export -alias ... -keystore server.keystore -rfc -file public.cert
+
+Creating the Truststore:
+keytool -import -alias ... -file public.cert -storetype JKS -keystore server.truststore
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/pgsql/ssl	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,67 @@
+http://www.howtoforge.com/postgresql-ssl-certificates
+
+On the server, three certificates are required in the data directory. CentOS default is /var/lib/pgsql/data/:
+root.crt (trusted root certificate)
+server.crt (server certificate)
+server.key (private key)
+
+Issue commands as root.
+
+sudo -
+
+cd /var/lib/pgsql/data
+
+Generate a private key (you must provide a passphrase).
+
+openssl genrsa -des3 -out server.key 1024
+
+Remove the passphrase.
+
+openssl rsa -in server.key -out server.key
+
+Set appropriate permission and owner on the private key file.
+
+chmod 400 server.key
+chown postgres.postgres server.key
+
+Create the server certificate.
+-subj is a shortcut to avoid prompting for the info.
+-x509 produces a self signed certificate rather than a certificate request.
+
+openssl req -new -key server.key -days 3650 -out server.crt -x509 -subj '/C=CA/ST=British Columbia/L=Comox/O=TheBrain.ca/CN=thebrain.ca/emailAddress=info@thebrain.ca'
+
+Since we are self-signing, we use the server certificate as the trusted root certificate.
+
+cp server.crt root.crt
+
+You need to edit postgresql.conf to actually activate ssl:
+
+ssl = on
+
+On the client, we need three files. For Windows, these files must be in %appdata%\postgresql\ directory. For Linux ~/.postgresql/ directory.
+root.crt (trusted root certificate)
+postgresql.crt (client certificate)
+postgresql.key (private key)
+
+Generate the the needed files on the server machine, and then copy them to the client. We'll generate the needed files in the /tmp/ directory.
+
+First create the private key postgresql.key for the client machine, and remove the passphrase.
+
+openssl genrsa -des3 -out /tmp/postgresql.key 1024
+
+openssl rsa -in /tmp/postgresql.key -out /tmp/postgresql.key
+
+Then create the certificate postgresql.crt. It must be signed by our trusted root (which is using the private key file on the server machine). Also, the certificate common name (CN) must be set to the database user name we'll connect as.
+
+openssl req -new -key /tmp/postgresql.key -out /tmp/postgresql.csr -subj '/C=CA/ST=British Columbia/L=Comox/O=TheBrain.ca/CN=www-data'
+
+openssl x509 -req -in /tmp/postgresql.csr -CA root.crt -CAkey server.key -out /tmp/postgresql.crt -CAcreateserial
+
+Copy the three files we created from the server /tmp/ directory to the client machine.
+
+Copy the trusted root certificate root.crt from the server machine to the client machine (for Windows pgadmin %appdata%\postgresql\ or for Linux pgadmin ~/.postgresql/). Change the file permission of postgresql.key to restrict access to just you (probably not needed on Windows as the restricted access is already inherited). Remove the files from the server /tmp/ directory.
+
+You must add "clientcert=1" to hostssl options for checking the client certificates, otherwise everyone will be granted access in your setup:
+hostssl all postgres 0.0.0.0/0 trust clientcert=1
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/scala/dsls	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,6 @@
+http://codetunes.com/2012/05/09/scala-dsl-tutorial-writing-web-framework-router
+http://idn.icw-global.com/solutions/ehealth-framework/articles/scala-dsls.html
+http://debasishg.blogspot.cz/2008/05/designing-internal-dsls-in-scala.html
+http://www.scala-lang.org/node/1403
+http://blog.engineering.vayana.in/case-study-in-dsl-development-with-scala-part-1/
+http://blog.engineering.vayana.in/case-study-in-dsl-development-with-scala-part-2/
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/ssl/certs.txt	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,5 @@
+Renew a self-signed cert
+http://www.togaware.com/linux/survivor/Renew_SSL.html
+
+openssl x509 -req -days 365 -in file.csr -signkey file.key -out file.crt
+cat file.key file.crt > file.pem
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/utils/tmux	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,10 @@
+tmux(1) tutorials, config examples:
+
+http://blog.hawkhost.com/2010/07/02/tmux-%e2%80%93-the-terminal-multiplexer-part-2/
+
+https://mutelight.org/practical-tmux
+
+http://helpful.knobs-dials.com/index.php/Screen_and_tmux
+
+http://superuser.com/questions/74492/whats-the-best-prefix-escape-sequence-for-screen-or-tmux
+
--- a/web-design/css-layouts	Fri Sep 02 17:01:42 2011 +0200
+++ b/web-design/css-layouts	Mon Jan 21 10:13:02 2013 +0100
@@ -7,3 +7,8 @@
 Roots is a starting WordPress theme made for developers that’s based on HTML5
 Boilerplate, Blueprint CSS (or 960.gs) and Starkers that will help you rapidly
 create brochure sites and blogs.
+
+http://www.freecsstemplates.org/
+All of my templates are free for any personal or commercial use (provided you
+follow the license) so you do not have to pay me anything to use them. All I
+ask is that you link back to my website (see the license for more details).
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/web-design/images	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,12 @@
+http://www.pdphoto.org/
+PDPhoto.org is a repository for public domain photos. Use the photos for
+anything, including commercial uses, other websites, school projects, articles,
+ads, whatever. Public domain means the photo is not protected by copyright and
+may be freely used by everyone. Unless something is clearly marked as being
+something other than public domain, you can assume it is free to use.
+
+http://www.freegraphicsworld.com/
+ - buttons, bullets, banners, backgrounds, templates, layouts
+You can use them for anything (even commercially). All of our graphics are
+licensed under the Creative Commons Attribution 3.0 license, so they are
+entirely free for personal and commercial as long as you credit us in some way.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/web-design/tables	Mon Jan 21 10:13:02 2013 +0100
@@ -0,0 +1,8 @@
+http://icant.co.uk/csstablegallery/
+Data Tables and Cascading Style Sheets Gallery
+The CSS Table Gallery is a showcase of how CSS and data tables can work together to create usable and pretty results.
+
+
+http://pythoughts.com/table-style-css/
+Table Style: CSS Examples of Good Looking HTML Tables
+