Thursday, May 8, 2008

Red5...just $%@*& work

Disclaimer: The title is just what I was thinking when I came up with compiler errors.

Well Red5 is turning out to be a great product and the price can't be beat. Like any software, though, there are a few bugs that need to be worked out. The biggest thing standing in it's path is a totally broken 0.7.0 release that won't even work out of the box. It's okay though, after searching around for a long while, I came across a fix from their bug reporting system.

It basically involves going back to the working ivy from the 0.6.3 release by replacing the ivy library jar in the lib folder, downloading a revised build.xml and ivyconfig.xml and placing them in your base installation directory, and then building with and. It may seem like an easy fix but I would think they wouldn't let this release out if you can't even run it.

I really want this software to progress so it is everything that Flash Media Server is and more (really it is more already). Just need to get those bugs worked out. So now I just want to say keep up a great project red5 guys, it's coming along great.

Monday, May 5, 2008

Update for Update for Firehol's get-iana.sh script

No, the title isn't a typo. The firehol mailing list received an update from ktsaou, the creator of firehol that the update had already been implemented in the CVS. I just wish that the changes would actually make it to release instead of just sitting inside of a CVS that seemingly no one checks. Enough of my little rant. If you want the updated version, you can get it from the CVS.

Friday, May 2, 2008

Update for Firehol's get-iana.sh script

I didn't notice very quickly but it was brought to my attention through the mailing list for firehol that the IANA Reserved IPs list formatting was updated. So I went through and did a little update to get it working again. This isn't 100% tested so use at your own risk.


#!/bin/bash

# $Id: get-iana.sh,v 1.11 2008/05/02 23:38:31 bdewong Exp $
#
# $Log: get-iana.sh,v $
#
# Revision 1.11 2008/05/02 23:38:31 bdewong
# Updated parsing of ipv4-address-space
#
# Revision 1.10 2007/05/05 23:38:31 ktsaou
# Added support for external definitions of:
#
# RESERVED_IPS
# PRIVATE_IPS
# MULTICAST_IPS
# UNROUTABLE_IPS
#
# in files under the same name in /etc/firehol/.
# Only RESERVED_IPS is mandatory (firehol will complain if it is not there,
# but it will still work without it), and is also the only file that firehol
# checks how old is it. If it is 90+ days old, firehol will complain again.
#
# Changed the supplied get-iana.sh script to generate the RESERVED_IPS file.
# FireHOL also instructs the user to use this script if the file is missing
# or is too old.
#
# Revision 1.9 2007/04/29 19:34:11 ktsaou
# *** empty log message ***
#
# Revision 1.8 2005/06/02 15:48:52 ktsaou
# Allowed 127.0.0.1 to be in RESERVED_IPS
#
# Revision 1.7 2005/05/08 23:27:23 ktsaou
# Updated RESERVED_IPS to current IANA reservations.
#
# Revision 1.6 2004/01/10 18:44:39 ktsaou
# Further optimized and reduced PRIVATE_IPS using:
# http://www.vergenet.net/linux/aggregate/
#
# The supplied get-iana.sh uses 'aggregate-flim' if it finds it in the path.
# (aggregate-flim is the name of this program when installed on Gentoo)
#
# Revision 1.5 2003/08/23 23:26:50 ktsaou
# Bug #793889:
# Change #!/bin/sh to #!/bin/bash to allow FireHOL run on systems that
# bash is not linked to /bin/sh.
#
# Revision 1.4 2002/10/27 12:44:42 ktsaou
# CVS test
#

#
# Program that downloads the IPv4 address space allocation by IANA
# and creates a list with all reserved address spaces.
#

IPV4_ADDRESS_SPACE_URL="http://www.iana.org/assignments/ipv4-address-space"
IANA_RESERVED="IANA\|Future use"

tempfile="/tmp/iana.$$.$RANDOM"

AGGREGATE="`which aggregate-flim 2>/dev/null`"
if [ -z "${AGGREGATE}" ]
then
echo >&2
echo >&2
echo >&2 "WARNING"
echo >&2 "Please install 'aggregate-flim' to shrink the list of IPs."
echo >&2
echo >&2
fi

echo >&2
echo >&2 "Fetching IANA IPv4 Address Space, from:"
echo >&2 "${IPV4_ADDRESS_SPACE_URL}"
echo >&2

wget -O - --proxy=off "${IPV4_ADDRESS_SPACE_URL}" |\
grep -e "${IANA_RESERVED}" |\
cut -d ' ' -f 1 |\
(
last=-1
while IFS="/" read range net
do
range=`expr $range + 0`
net=`expr $net + 0`

if [ ! $net -eq 8 ]
then
echo >&2 "Cannot handle network masks of $net bits ($range/$net)"
continue
fi

if [ $range -gt $last ]
then
echo "$range.0.0.0/$net"
last=$range
fi
done
) | \
(
if [ ! -z "${AGGREGATE}" -a -x "${AGGREGATE}" ]
then
"${AGGREGATE}"
else
cat
fi
) >"${tempfile}"

echo >&2
echo >&2
echo >&2 "FOUND THE FOLLOWING RESERVED IP RANGES:"
printf "RESERVED_IPS=\""
i=0
for x in `cat ${tempfile}`
do
i=$[i + 1]
printf "${x} "
done
printf "\"\n"

if [ $i -eq 0 ]
then
echo >&2
echo >&2
echo >&2 "Failed to find reserved IPs."
echo >&2 "Possibly the file format has been changed, or I cannot fetch the URL."
echo >&2

rm -f ${tempfile}
exit 1
fi
echo >&2
echo >&2
echo >&2 "Differences between the fetched list and the list installed in"
echo >&2 "/etc/firehol/RESERVED_IPS:"

echo >&2 "# diff /etc/firehol/RESERVED_IPS ${tempfile}"
diff /etc/firehol/RESERVED_IPS ${tempfile}

if [ $? -eq 0 ]
then
echo >&2
echo >&2 "No differences found."
echo >&2

rm -f ${tempfile}
exit 0
fi

echo >&2
echo >&2
echo >&2 "Would you like to save this list to /etc/firehol/RESERVED_IPS"
echo >&2 "so that FireHOL will automatically use it from now on?"
echo >&2
while [ 1 = 1 ]
do
printf >&2 "yes or no > "
read x

case "${x}" in
yes) cp -f /etc/firehol/RESERVED_IPS /etc/firehol/RESERVED_IPS.old 2>/dev/null
cat "${tempfile}" >/etc/firehol/RESERVED_IPS || exit 1
echo >&2 "New RESERVED_IPS written to '/etc/firehol/RESERVED_IPS'."
break
;;

no)
echo >&2 "Saved nothing."
break
;;

*) echo >&2 "Cannot understand '${x}'."
;;
esac
done

rm -f ${tempfile}

Thursday, May 1, 2008

Skip Annoying OpenOffice Registration Screen

I just wanted to post about a helpful tip that I came across to skip the registration wizard in OpenOffice.org when installing from an administrative install point. Edit the setup.xcu file in "OpenOfficeInstallDirectory\share\registry\res\en-US\org\openoffice\setup.xcu" to look like the following:


<?xml version="1.0" encoding="UTF-8"?>
<oor:component-data oor="http://openoffice.org/2001/registry" xs="http://www.w3.org/2001/XMLSchema" name="Setup" package="org.openoffice">
<node name="L10N">
<prop name="ooLocale" type="xs:string">
<value>en-US</value>
</prop>
</node>
<node name="Office">
<prop name="LicenseAcceptDate" type="xs:string">
<value>2008-04-29T06:44:17</value>
</prop>
<prop name="MigrationCompleted" type="xs:boolean">
<value>true</value>
</prop>
<prop name="FirstStartWizardCompleted" type="xs:boolean">
<value>true</value>
</prop>
<node name="Factories">
<node name="com.sun.star.text.TextDocument">
<prop name="ooSetupFactoryWindowAttributes" type="xs:string">
<value>48,67,952,723;4;0,0,0,0;</value>
</prop>
</node>
<node name="com.sun.star.sheet.SpreadsheetDocument">
<prop name="ooSetupFactoryWindowAttributes" type="xs:string">
<value>180,199,952,723;4;0,0,0,0;</value>
</prop>
</node>
<node name="com.sun.star.drawing.DrawingDocument">
<prop name="ooSetupFactoryWindowAttributes" type="xs:string">
<value>246,265,952,723;4;0,0,0,0;</value>
</prop>
</node>
<node name="com.sun.star.text.WebDocument">
<prop name="ooSetupFactoryWindowAttributes" type="xs:string">
<value>139,194,952,723;1;0,0,0,0;</value>
</prop>
</node>
<node name="com.sun.star.presentation.PresentationDocument">
<prop name="ooSetupFactoryWindowAttributes" type="xs:string">
<value>92,111,952,723;4;0,0,0,0;</value>
</prop>
</node>
<node name="com.sun.star.frame.StartModule">
<prop name="ooSetupFactoryWindowAttributes" type="xs:string">
<value>136,155,952,723;4;0,0,0,0;</value>
</prop>
</node>
</node>
</node>
</oor:component-data>