Text Message Blocking on Sprint

November 9th, 2011

A useful feature I did not know was available on Sprint.

From your cell phone, you can block text messages from any number (including short codes) from getting through to your phone by texting “block NUMBER” (without quotes, and where NUMBER is obviously the phone number or short code you wish to block) to 9999.

You will get a response back confirming that text messages from that number are blocked, and you’re good to go!

Posted in Tech Stuff | Comments (0)

Firefox ssl_error_renegotiation_not_allowed

September 29th, 2011

Was receiving this error on one of my client’s intranet sites when accessed from outside their network, only when using Firefox.

The solution is a setting in Firefox’s “about:config” page.  CAUTION: This could allow malicious activity (I’m unsure), I don’t take any responsibility for your machine catching on fire, killing your house pets or uploading your dirty pictures to Facebook.

Go to “about:config” in Firefox, search for “security.ssl.allow_unrestricted_renego_everywhere__temporarily_available_pref”, and set it to “true”.

You’re done.  Page should work properly now.

Posted in Tech Stuff | Comments (0)

SSL Certificates on Apache

September 29th, 2011

I needed to take a PFX certificate being used on IIS and move it to an Apache server (It’s a wildcard certificate).

Found a few helpful web pages, but the gist of the process is this:

- Export to PFX in IIS
- Copy the PFX to the Unix host
- Then execute the following on the Unix Host:

# Export the private key file from the pfx file
openssl pkcs12 -in filename.pfx -nocerts -out key.pem
# Export the certificate file from the pfx file
openssl pkcs12 -in filename.pfx -clcerts -nokeys -out cert.pem
# This removes the passphrase from the private key so Apache won’t
# prompt you for your passphase when it starts
openssl rsa -in key.pem -out server.key

Now you have the 2 important files from the PFX that you need for Apache – server.key and cert.pem.

All you need to do is create the VirtualHost directive for the SSL site and add the following parts inside of it:

SSLEngine on
SSLCertificateFile /etc/ssl/private/cert.pem
SSLCertificateKeyFile /etc/ssl/private/server.key

via Moving an IIS certificate to a nix / Apache2 / OpenSSL server and SSL Certificate Installation – Apache Server

Posted in Tech Stuff | Comments (0)

Remove Spotlight’s menubar icon in Snow Leopard

November 1st, 2010

This is just a simple tip on how to safely remove the Spotlight icon from your menubar. I disable Spotlight completely on my system (run the following terminal command if you’d like to do the same: sudo mdutil -a -i off), but even if you do use Spotlight, this solution shouldn’t affect its operation, just the icon. (UPDATE: This likely will disable any keyboard shortcuts used to invoke Spotlight.)

One way to kill the icon is to remove or rename the Search.bundle package found at /System/Library/CoreServices. Obviously though, by renaming or deleting the bundle you run the risk of something breaking if a future software update attempts to read from or write to it. Another possible solution is to remove or replace with a “blank” PDF the MDSearchMenuIcon.pdf file within the /Contents/Resources/ directory of Search.bundle, but I suspect that while this may remove the icon, the space allocated to it in the menubar will persist.

To obviate these issues, you simply can change the permissions on the Search file within Search.bundle so that only root can read from and write to the file. By doing this, you ensure that 1) you (and other users of the system) can’t read from the file; and 2) any future updates via Software Update can transpire without issue.

You can set the proper permissions by executing the following terminal command:

sudo chmod 600 /System/Library/CoreServices/Search.bundle/Contents/MacOS/Search

Next, restart SystemUIServer by issuing the killall SystemUIServer terminal command.

via Justin Blanton.

Tags: , ,
Posted in Tech Stuff | Comments (0)

Rewrite Outgoing Addresses with Postfix

July 21st, 2010

Address rewriting allows changing outgoing email ID or domain name itself. This is good for hiding internal user names. For example:
SMTP user: tom-01
EMAIL ID: tom@domain.com
Server name: server01.hosting.com

However when tom-01 sends an email from shell prompt or using php it looks like it was sent from tom-01@server01.hosting.com.

In some cases internal hosts have no valid Internet domain name, and instead use a name such as localdomain.local or something else. This can be a problem when you want to send mail over the Internet, because many mail servers reject mail addresses with invalid domain names to avoid spam.

Postfix MTA offers smtp_generic_maps parameter. You can specify lookup tables that replace local mail addresses by valid Internet addresses when mail leaves the machine via SMTP.

Open your main.cf file
# vi /etc/postfix/main.cf

Append following parameter
smtp_generic_maps = hash:/etc/postfix/generic

Save and close the file. Open /etc/postfix/generic file:
# vi /etc/postfix/generic

Make sure tom-01@server01.hosting.com is changed to tom@domain.com
tom-01@server01.hosting.com tom@domain.com

Save and close the file. Create or update generic postfix table:
# postmap /etc/postfix/generic

Restart postfix:
# /etc/init.d/postfix restart

When mail is sent to a remote host via SMTP this replaces tom-01@server01.hosting.com by tom@domain.com mail address. You can use this trick to replace address with your ISP address if you are connected via local SMTP.

via NixCraft.

Tags: , ,
Posted in Tech Stuff | Comments (0)

SSH Tunnel/SOCKS Proxy

May 17th, 2010

Instructions are for Mac, YMMV.

Enter the following command into Terminal, replacing myuser@myserver.com for the username/host where you have SSH access:
ssh -D 8080 -f -C -q -N myuser@myserver.com

Thats it!  You may now configure localhost:8080 as a SOCKS proxy in your browser (see the link below for generic/Safari instructions – Firefox is configured in Preferences -> Advanced -> Network -> “Settings”).

How To: Surf Securely with an SSH Tunnel — PaulStamatiou.com.

Posted in Tech Stuff | Comments (0)

Hide Accounts from Windows Login Screen

May 4th, 2010

Login accounts can be hidden from the Windows Welcome/login screen by creating a registry key as follows:

HKLM\Software\Microsoft\Windows NT\CurrentVersion\WinLogon\SpecialAccounts\UserList
Add DWORD for “AccountName” and set value to 0 to hide it from the UI

I use this for setting up Access Code authentication with LogMeIn after LMI has been installed.  You can create the LogMeInRemoteUser, add it to the Administrators group, then create a registry key in the above matching the username.

Posted in Tech Stuff | Comments (0)

Convert WAV file for use with Asterisk greetings/IVR

April 29th, 2010

If file1.wav is any WAV file, then executing this command: sox file1.wav -r 8000 -c 1 -s file2.wav resample -ql you will get Asterisk playable WAV file: file2.wav.

sox is a free download from http://sox.sourceforge.net/ for Windows, Mac OS X and Linux.

The “resample” option is deprecated in the most recent version of sox (v14.3.1), but still works and only throws up a warning.

I use the following script to convert a batch of files:

mkdir new
for I in $(ls -1 *.wav)
do
NAME=$I
echo “Converting $NAME”
sox $NAME -r 8000 -c 1 -s new/$NAME resample -ql
echo “Output filename: new/$NAME”
done

Posted in Tech Stuff | Comments (0)

Save non-savable PDF files

April 1st, 2010

Occasionally one has to use an annoying PDF that one can’t re-save, but can only print. My sister had this situation dealing with some obnoxious state-run Microsoft system that didn’t allow the user to save a completed form, only to print it from a browser. The individual administering the system apparently flipped the wrong bit, as last year, the form could be saved.Here’s a workaround, various versions of which can allow you to save the PDF:

1. Turn off the print queue for the printer by going to Printer Setup Utility.

2. Print the file, but don’t reactivate the printer — choose the Add to Queue option.

3. Go into the terminal and su to root. If you haven’t enabled root, use sudo -s to start a root shell.

4. Type cd /var/spool/cups, then identify the file you just printed. Do this by matching the queued file’s time stamp to the time you printed the file ls -l; the file of interest should be at the bottom.

5. Copy don’t move that file out of the spool folder: cp filename ~/Desktop. I don’t know what a move mv will do to the print system.

6. Type cd ~/Desktop to move to your user’s Desktop folder.

7. Type chown myaccount:myaccount filename to make sure the Finder in your user space will play nicely with the file.

8. Peek inside the file and determine whether it’s a postscript or PDF file — you can drop it on TextEdit to see its contents. If it’s a postscript file, rename the file to filename.ps. If it’s a PDF file, rename it to filename.pdf.

9. Confirm the above by dropping the file on Preview. If the file is a postscript file, you can then save it as a PDF file from Preview.

via Save non-savable PDF files – Mac OS X Hints.

Tags: , , , ,
Posted in Tech Stuff | Comments (0)

Disable AirPort when Ethernet cable is connected – Mac OS X Hints

March 15th, 2010

hellomrzebra415 writes: “At my office, I needed to find a way to turn of the wireless network when someone plugged in their network cable. I also did not want them to be able to turn the wireless network back on until the network cable was unplugged. I came up with the fallowing solution.

via Mac OS X Hints.

Posted in Tech Stuff | Comments (0)

Recent Posts