## Samba and Firewall Configuration

I’ve been using Guarddog as a GUI for iptables for some time. I’ve configured it to allow to connect to samba network shares but for some reason it won’t allowed me connect to the shares without the disabling the firewall first. The blockage happened despite the proper configuration in Guarddog. So today I decided to look again at the problem and fix it.

After inspecting the output of ‘dmesg’ I found out that it tries to connect to 192.168.2.255 (192.168.2.* is my network), which is the broadcast address for the network. I tried enabling connection to the address and to my surprise this fixed the problem. I guess samba for some reason requires access for the broadcast for some name/address lookup of hosts in the network.

## Prevent Line Breaking Inline Formula in Tex/Latex

If you ever wrote a document in latex (or tex) that used inline formulas you know how frustrating it is when latex insists on breaking you inline formula across two lines. The easiest solution to this problem, in my opinion is to prevent line breaking inline formulas at all except under extreme cases. To prevent line breaking inline formulas just add the following two lines into your preamble:

```\relpenalty=9999 \binoppenalty=9999```

Now I will explain what we did. `\relpenalty=[number parameter]` the parameter speciﬁes the penalty for breaking a math formula after a relation when the formula appears in a paragraph. Plain TEX sets `\relpenalty` to 500. `\binoppenalty=[number parameter]` the parameter speciﬁes the penalty for breaking a math formula after a binary operator when the formula appears in a paragraph. Plain TEX sets `\binoppenalty` to 700. Both parameters can be set anywhere from 0 to 10000. If set to 10000 the inline formulas will never break even in extreme cases. Setting it a bit lower would prevent line breaking except where tex would encounter extreme cases which must have a line break because of the situation.

## Using Hebrew TrueType fonts with pdfTeX

This guide is base on a guide published by Dekel Tsur that can be found here. Dekel Tsur’s guide was very good but now it is outdated since it doesn’t work with teTex 3.0. In this guide I addressed this issue and updated the instructions and scripts so it will work with teTex 3.0.Since the quality of the Hebrew metafonts that comes with the Hebrew LaTeX is quite poor, alternative fonts are needed. The best quality free Hebrew fonts are TrueType fonts (for example, the times new/arial/courier new fonts). Using TrueType fonts with TeX is somewhat complicated, but it is quite easy with pdfTeX, as pdfTeX has native support for TrueType fonts. This document explains how to use TrueType fonts with pdfTeX. Since Hebrew requires the use of the eTeX engine, you need to have the pdfelatex program. It is available in teTeX 1.0 (which comes with recent Linux distributions). The instruction below allows using nikud, although the result is quite poor as the nikud glyphs are not aligned correctly (but it is better than nothing).