Wednesday, October 29, 2008

PuTTY, SSH, Web Browser tunnel

This bypasses your proxy server, tunnels through your own SSH server, and provides web access.
  1. Have a running ssh server, accessible from the Internet. http://www.dyndns.com can help give you a name to your IP address, if you have a dynamic one. Making the dyndns connection is beyond the scope of this tutorial.
  2. Create a PuTTY session to your ssh server. Chances are, if you know what step 1 is about, you've already created a PuTTY session to it.
  3. Inside PuTTY's session, go to Connection, SSH, Tunnels
  4. Type a number (8080?) into Source Port. Click Dynamic, Auto, and then [Add]
  5. Save the PuTTY sesssion
  6. Connect to your PuTTY session
  7. Configure your browser's proxy settings: Manual, SOCKS v5, 127.0.0.1, port (whatever number you used as your Source Port in 4.)
  8. If you go to http://www.gwy.org/yourip.php, you should now see that your IP address is your ssh server.
There are interesting side effects that happen when you do this, especially since you usually can ssh connect any time you have any internet access.

Tuesday, October 28, 2008

ImageMagick is cool

Command line for images? What?

OK, so I have this .png file that makes a bevel on a picture:
except I don't *really* want to take the time and effort to load GIMP/Photoshop every time I want to apply this bevel/bezel. Now, I take ImageMagick's convert and composite and make my button from the command line:

convert -resize 244x132! originalpic.jpg resizedpicname.jpg
composite bevel.png resizedpicname.jpg buttonizedfilename.jpg



Original: Trent Original Photo
Resized: Trent resized Photo
Bevel/Bezel: Trent buttonized

Wednesday, October 8, 2008

The Devil you know

Better the devil you know... that means that people would rather vote for someone decisive in what they believe (even if they think he's lying) than to vote for ambiguous policies.

You know Obama is feeding you a load of junk. He's cute and he explains the junk he's selling. It's still junk. But then you have McCain saying stuff. You don't know what he's selling. You don't know what you can do with what he's selling. You're not even certain HE knows what he's selling. All he wants to do is call you "my friends." You're wary about what he wants to do. "The devil you know" may lead you to the path of destruction. "The devil you don't know" perhaps can't or won't lead you anywhere.

In essence, you're the Gingerbread Man, Obama's the fox who'll carry you across the water. He'll probably eat you, but you're dry and in motion away from the other doom. McCain is the river. You could jump in the river. You could be safe, but then you could be a soggy mess.

Monday, October 6, 2008

New Monty Hall Puzzle(s)

Based upon some comments in the other Monty Hall puzzle, I propose the following scenarios:

Three doors which the host knows the location of a car and two goats. Two contestants get to choose SEPARATE doors.

  • Scenario 1: The host always opens the non-chosen door, regardless of car or goat. A car shown means both contestants lose immediately. No choice offered.
  • Scenario 2: The host always opens either goat door that does not declare a winner, but can declare a loser (random goat 1/2)
  • Scenario 3: The host always opens the non-chosen door if it's a goat (2/3), but chooses a random contestant's door if the non-chosen door is a car.
  • Scenario 3a: The contestants do not know this rule
  • Scenario 3b: The contestants do know this rule

In each scenario, the option to switch is given, not forced. In what cases is it advantageous to switch?


The billion door equivalencies:

  • Scenario 1: The host always opens the 1 billion minus 2 remaining doors
  • Scenario 1a: There is one remaining door and 1 billion minus 1 contestants

As I'm running through the permutations of this in my head, I realize that adding multiple contestants greatly convolutes the problem. With two contestants head to head, the math is indicative that at least one of the contestants is likely to have chosen the car (2 contestants out of 3 choices). More contestants means it's more likely that one of the contestants have already won the car. With multiple contestants already knowing that one of their set has the car, there appears to be little incentive to change even if the host shows a goat. However, if the host starts showing known losers the set of unopened doors plus shown losers increases the probability that the subset of unopened doors more likely contains the car than the original probability of the set of original choice of doors versus the set of total doors.

Blog Archive