Thursday, September 29, 2011

How to NOT Ask for Help in Open Source

Here is a slightly edited extract of the IRC chat I saw today. WARNING: coarse language ahead.


In case you don't want to read the whole thing:
  1. User barges in the dev channel and asks for a full-blown feature to be implemented
  2. User does not listen to the devs who give some information to answer the question
  3. User mocks devs who exchange some thoughts related to the implementation of the feature
  4. User complains that the devs who are trying to help are wasting his time, when in fact he is wasting theirs.
  5. User ignores the polite request to calm down
  6. User gets kicked by a senior dev
Lessons:
  1. Being humble really helps
  2. Listening to the answers to your question is really simple and helps a lot
  3. Insulting people isn't helping
  4. Not everything in software can be done easily

(05:17:24 PM) Kicksyourballs: So how can I hack open office to remove the stopping of me embedding my fonts in my documents?
(05:18:19 PM) thorsten: Kicksyourballs: no idea 'bout OOo, but for LibO: http://www.libreoffice.org/get-involved/developers/
(05:18:42 PM) Kicksyourballs: So how can I hack open office to remove the stopping of me embedding my fonts in my documents? - does any one know HOW to do do it?
(05:19:48 PM) Kicksyourballs: Yeah I have been fighting this fight big time for a long time - I am only intereseted in a solution, or doing what ever it takes to achieve that result.
(05:20:17 PM) thorsten: Kicksyourballs: sounds good - so best not waste time in discussion, but get some code rolled to support it -
(05:21:32 PM) Kicksyourballs: a) I CAN code - and if I apply myself to learning how to do it, I can and will but I'd rather speed the process up by simply finding the part of the coding that says "NO FONT EMBEDDING" and remove / edit / alter it
(05:22:00 PM) Kicksyourballs: And then publically announce the hack.
(05:22:07 PM) thorsten: Kicksyourballs: wrong assumption. it's simply missing - and needs extra code to handle it, at a bunch of places ...
(05:22:40 PM) frob_tea: Kicksyourballs: could you also look for "NO MAKING EVERYTHING GREAT BUTTON" and remove it?
(05:23:26 PM) Kicksyourballs: Yeah well - this info is not exactly publically advertised - "OK so you think us stopping you from embedding your own fonts in your own work sucks - here's how"
(05:23:56 PM) tml_: thorsten: and leaving out half of the glyphs, it would no longer be immoral to embed (if the creator of the font doesn't want you to embed it) ?
(05:24:32 PM) thorsten: tml_: no moral judgement at all involved - it's simply considered permissible by case law it seems
(05:24:43 PM) thorsten: fair use, yadda yadda
(05:25:08 PM) Kicksyourballs: I am am not intertested in arguing the issue, or the pro's and con's or debating it - I want to embed my own fonts in my own documents - and this is how it is going to be: http://tinyurl.com/3oyjeuo http://tinyurl.com/6kyk3ps http://tinyurl.com/6l5vtet http://tinyurl.com/44z8yqa
(05:25:10 PM) tml_: don't some font formats have information in them what one is allowed to do with the font?
(05:25:16 PM) thorsten: tml_: yes
(05:26:03 PM) tml_: Kicksyourballs: screaming "Fuck Ubuntu" doesn't exactly improve your credibility, make us think "this guy must be a good coder"
(05:26:06 PM) thorsten: tml_: still, subsetting is considered acceptable - that's what's used in pdf exports all across the globe, and also MSO ...
(05:26:10 PM) Kicksyourballs: Do the people here expressing opinions actually know how to do it? If you do, share it - if not - don't waste my time.
(05:26:27 PM) tml_: Kicksyourballs: no we don't, we are just kicking your nuts
(05:26:28 PM) frob_tea: Kicksyourballs: it was already shared
(05:26:46 PM) frob_tea: Kicksyourballs: calm down
(05:27:12 PM) Kicksyourballs: Thorsten - I am not interested in what you think - either you have a solution or you don't. If you do, share it - if you don't don't waste my time.
(05:28:03 PM) tml_: Kicksyourballs: maybe you should join that other OOo -based project instead, they are much more friendly
(05:28:36 PM) Kicksyourballs: So this is where the dick heads hang out...... opinions about everything - solutions to nothing.
(05:28:45 PM) Sweetshark: Kicksyourballs: this is the wrong channel. Unless you have a patch.
(05:29:12 PM) thorsten: Kicksyourballs: starts to get inacceptable - behave, or leave.
(05:29:15 PM) Kicksyourballs: http://tinyurl.com/3oyjeuo http://tinyurl.com/6kyk3ps http://tinyurl.com/6l5vtet http://tinyurl.com/44z8yqa - Sure......
(05:29:29 PM) Kicksyourballs: Dumb Fucks.
(05:29:36 PM) tml_: lol
(05:29:48 PM) ***Sweetshark giggles.
(05:29:49 PM) tml_: "fix my bugs, or! I know where you live!"
(05:30:02 PM) Kicksyourballs: LOL
(05:30:29 PM) frob_tea: tml_ "and which school your kids are going!"
(05:30:57 PM) Kicksyourballs: The low IQ one handed typists are such fun... "Oh well I think this, I think that" - "Do you know how to fix it?" No then fuck off.
(05:31:30 PM) Sweetshark: Kicksyourballs: Why dont you join dev.openoffice.org and explain to them how awesome you find their native linux packages?
(05:31:55 PM) Kicksyourballs: Oh Oh I am a Open Orifice developer... I have opinions to everything and solutions to nothing.... I'll hang out here with my other cool buddies.
(05:32:24 PM) Kicksyourballs left the room (Kicked by dtardon (Kicksyourballs)).
(05:32:30 PM) frob_tea: dtardon: thank you
(05:33:23 PM) tml_: you just have to love Open Source enthusiasts
(05:33:28 PM) Sweetshark: dtardon: now that is dry -- not even talking to the troll once.
(05:34:05 PM) dtardon: Sweetshark, i'm not so good at talking ;)
(05:34:31 PM) Sweetshark: dtardon: but your kicking moves are quite hamdsome ;)

Tuesday, September 27, 2011

A Faster LibreOffice Build

How about building LibreOffice faster? So I am giving another post about boosting your LO build speed, starting from scratch.

Short story: system libraries are your friend. Now, it is not super easy to make a build that is using 100% system libraries, but you can go a long way with this, and very easily too.

Reminder: I am doing this from Fedora 15 system with an Icecream cluster.

This is the procedure:
1. Clone the latest repository. If you are behind a firewall, use corkscrew
git clone ssh://git.freedesktop.org/git/libreoffice/core.git

2. Set up build dependencies
sudo yum-builddep libreoffice
sudo yum install icecream
sudo yum install zlib-devel libjpeg-devel poppler-devel sane-backends-devel curl-devel boost-devel cppunit-devel libpng-devel

3. Configure and Icecream
sudo vim /etc/sysconfig/icecream
sudo /etc/init.d/iceccd restart
sudo chkconfig iceccd on
icecc --build-native
mkdir ~/.icecc
mv <whatever icecc generated> ~/.icecc/icecc-env.tar.gz
echo "export ICECC_DEBUG=debug">> ~/.bashrc
echo "export ICECC_VERSION=~/.icecc/icecc-env.tar.gz" >>~/.bashrc

4. Generate make files

./autogen.sh --enable-icecream --with-gcc-home=/usr/lib/icecc --with-num-cpus=16 --with-max-jobs=16 --enable-symbols--with-system-libs --with-system-headers

5. Build
make; make dev-install

Monday, September 26, 2011

Setting up LibreOffice For Fuzz Testing

I will assume that your VM is properly set up with the CERT BFF :)

Now, you will need to install Java, which you can download from Oracle.
To do so
1. Copy to your virtual machine's shared folder
2. Create the target installation directory, e.g. /usr/java
3. Run the unpacking, e.g. sudo /.../jre-6u26-linux-i586.bin
4. Add to your path: sudo vim /etc/profile and add PATH=$PATH:/usr/java/jre1.6.0_26/bin
5. Source the new setting: source /etc/profile

Then you will need a reasonably recent copy of LibreOffice. For instance, the latest bundle of debs. After you got that
1. Copy to your virtual machine's shared folder
2. Unpack: tar xvfz  LibO_3.4.2_Linux_x86_install-deb_en-US.tar.gz
3. cd  LibO_3.4.2rc3_Linux_x86_install-deb_en-US
4. sudo dpkg -i *.deb
5. Add to your path sudo vim /etc/profile and add PATH=$PATH:PATH=$PATH:/opt/libreoffice3.4/program
6. Source the new setting: source /etc/profile

After you did all that, it is a good idea to power down and take a snapshot of your virtual machine.
Once this is done,
1. Unzip the scripts folder into the directory shared with the virtual machine
2. vim bff.cfg and replace as follows
program=soffice
killprocname=soffice.bin
preargs=
postargs=
seedfile=seed.doc
zzuftimeout=30
killproctimeout=60
gdbtimeout=30
valgrindtimeout=120

You should be good to go. Try starting you VM and the fuzz testing should happen automatically


CERT Basic Fuzzing Framework in QEmu

Here is a follow-up post on how to use QEmu to run the BFF from CERT. Since the support for sharing files between host and guest OSes is not always there, I'm suggesting to use another method for that. In this case, I'll just copy the files in the VM.

I assume you already downloaded the files from CERT, so I will not repeat that.

1. Convert to qemu format
qemu-img convert DebianFuzz.vmdk -O qcow2 DebianFuzz-copy.qemu
2. Copy to whichever system will run it
scp DebianFuzz-copy.qemu myvmhost:
3. Login to that host and start the VM with network support and VNC
sudo qemu-system-x86_64 -m 512 ~/DebianFuzz-copy.qemu -vnc :1 -net nic -net tap
4. Connect using Remmina to myvmhost:5901
5. In the, VM connect to the network using DHCP
dhclient eth1
6. Change your apt configuration if needed
7. Install OpenSSH
su -c "apt-get install ssh"
8. Copy the data from your own box
scp -r mydesktop:~/fuzz-shared ~/fuzzing
9. Configure a symlink:
sudo ln -s /mnt/hgfs/fuzz /home/fuzz/fuzzing
10. Restart the VM
sudo shutdown -r now

While this officially runs 'fine', I personally have not been too happy with it. Things are slow, and the results we get are only in a log file. So that means hours of fuzzing and I don't even get a sample to test with!

Thursday, September 22, 2011

Fear of the Lord

The Fear of the Lord is an unpopular idea. We typically understand that God is all about love, and there shouldn't be any reason to fear, right?

Well, the Bible tells us to have a more balanced view: having both fear and love. How is that possible? Is it Stockholm Syndrome? Read on...

Sunday, September 11, 2011

Reflexions on the Historical Adam

Whether you like it or not, the false issue of Creation vs. Evolution is the dominant intellectual roadblock on their way to a relationship with God.

So, here is my feeble attempt at helping my brothers and sisters in the faith dealing with our Biblical ancestor, Adam.