<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -10,6 +10,12 @@ else {
     $file_list = array(SNAP_WI_TEST_PATH);
 }
 
+if (SNAP_WI_CRYPT) {
+    foreach ($file_list as $idx =&gt; $file) {
+        $file_list[$idx] = snap_blowfish_encrypt($file, SNAP_WI_CRYPT);
+    }
+}
+
 echo json_encode($file_list);
 
 exit;</diff>
      <filename>core/util/webfiles/getfiles.php</filename>
    </modified>
    <modified>
      <diff>@@ -60,7 +60,18 @@ $urls = array(
     &lt;/div&gt;
     &lt;dl id=&quot;testing_parameters&quot;&gt;
         &lt;dt&gt;Test Path:&lt;/dt&gt;
-        &lt;dd&gt;&lt;?php echo SNAP_WI_TEST_PATH ?&gt;&lt;/dd&gt;
+        &lt;dd&gt;&lt;?php 
+            if (SNAP_WI_CRYPT) {
+                $crypt = snap_blowfish_encrypt(SNAP_WI_TEST_PATH, SNAP_WI_CRYPT);
+                $crypt = str_replace('_', '', $crypt);
+                $crypt = substr($crypt, -32);
+                echo $crypt;
+                echo &quot; &lt;strong&gt;(File obfuscation is on)&lt;/strong&gt;&quot;;
+            }
+            else {
+                echo SNAP_WI_TEST_PATH;
+            }
+        ?&gt;&lt;/dd&gt;
         
         &lt;dt&gt;Test Match:&lt;/dt&gt;
         &lt;dd&gt;&lt;?php echo SNAP_WI_TEST_MATCH ?&gt;&lt;/dd&gt;</diff>
      <filename>core/util/webfiles/index.php</filename>
    </modified>
    <modified>
      <diff>@@ -222,7 +222,9 @@ YAHOO.SnapTest.DisplayManager = (function() {
 		var p = document.createElement(&quot;p&quot;);
 		YAHOO.util.Dom.addClass(p, &quot;file_name&quot;);
 		
-		var txt = document.createTextNode(file);
+		var fileDisplay = file;
+		fileDisplay = fileDisplay.substr(fileDisplay.length - 32, 32);
+		var txt = document.createTextNode(fileDisplay);
 		
 		YAHOO.util.Dom.get(YAHOO.SnapTest.Constants.TEST_LIST).appendChild(li);
 			li.appendChild(makeFoldingControl());</diff>
      <filename>core/util/webfiles/js/displaymanager.js</filename>
    </modified>
    <modified>
      <diff>@@ -13,6 +13,12 @@ if (!$options['file']) {
 }
 
 $file = $options['file'];
+$file_original = $options['file'];
+
+// decrypt if required
+if (SNAP_WI_CRYPT) {
+    $file = snap_blowfish_decrypt($file, SNAP_WI_CRYPT);
+}
 
 // ensure file path matches test path prefix
 $file = str_replace(array('..', '//'), array('.', '/'), $file);
@@ -34,7 +40,7 @@ $output = array();
 foreach ($results as $klassname =&gt; $classes) {
     if (!is_array($classes)) {
         $out = array();
-        $out['file'] = $file;
+        $out['file'] = $file_original;
         $out['error'] = $classes;
         $output[] = $out;
         continue;
@@ -42,7 +48,7 @@ foreach ($results as $klassname =&gt; $classes) {
     
     foreach ($classes as $klass =&gt; $test) {
         $out = array();
-        $out['file'] = $file;
+        $out['file'] = $file_original;
         $out['klass'] = $klassname;
         $out['test'] = $test;
         $output[] = $out;</diff>
      <filename>core/util/webfiles/loadtests.php</filename>
    </modified>
    <modified>
      <diff>@@ -18,6 +18,11 @@ $file = $options['file'];
 $test = $options['test'];
 $klass = $options['klass'];
 
+// decrypt if required
+if (SNAP_WI_CRYPT) {
+    $file = snap_blowfish_decrypt($file, SNAP_WI_CRYPT);
+}
+
 // ensure file path matches test path prefix
 $file = str_replace(array('..', '//'), array('.', '/'), $file);
 </diff>
      <filename>core/util/webfiles/runtest.php</filename>
    </modified>
    <modified>
      <diff>@@ -22,10 +22,19 @@ define('SNAP_WI_URL_PATH', 'http://www.example.com/path/to/snaptest_web.dist.php
 // A blank string means no key will be used.
 define('SNAP_WI_KEY', '');
 
-// STEP 5: set the matching path Files matching this pattern will be testable
+// STEP 5: Obfuscation key. If you decided to set a key for STEP 4, then
+// you may want a key for STEP 5. Setting a crypt key will obfuscate all
+// path information in the web interface. Great if you want to show off your
+// test results without exposing your path to the world. Is this wise?
+// I suppose that'd be your call.
+// A blank string means no obfuscation will be done.
+define('SNAP_WI_CRYPT', '');
+
+// STEP 6: set the matching path
+// Files matching this pattern will be testable
 define('SNAP_WI_TEST_MATCH', '^.*\.stest\.php$');
 
-// STEP 6: Relax, you're done.
+// STEP 7: Relax, you're done. Bask in your awesomeness.
 // Go to http://www.example.com/path/to/snaptest_web.dist.php
 
 // --------------------------------------------------------------------------</diff>
      <filename>snaptest_web.dist.php</filename>
    </modified>
    <modified>
      <diff>@@ -26,6 +26,11 @@ if (SNAP_WI_KEY) {
     }
 }
 
+// include the blowfish library if they are crypting
+if (SNAP_WI_CRYPT) {
+    require_once dirname(__FILE__) . DIRECTORY_SEPARATOR . 'core' . DIRECTORY_SEPARATOR . 'util' . DIRECTORY_SEPARATOR . 'blowfish' . DIRECTORY_SEPARATOR . 'blowfish.php';
+}
+
 Snap_Request::setURLBase(SNAP_WI_URL_PATH);
 
 switch ($options['mode']) {</diff>
      <filename>snaptest_webcore.php</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>ded9ccd88582b9405bcdeeae19028943ae5aa1bd</id>
    </parent>
  </parents>
  <author>
    <name>Jakob Heuser</name>
    <email>jakob@felocity.org</email>
  </author>
  <url>http://github.com/Jakobo/snaptest/commit/de550048bb3c5ef978be030f522b886af93725ba</url>
  <id>de550048bb3c5ef978be030f522b886af93725ba</id>
  <committed-date>2009-06-08T02:11:27-07:00</committed-date>
  <authored-date>2009-06-08T02:11:27-07:00</authored-date>
  <message>obfuscation support completed, closes #16</message>
  <tree>f4532aac7c77dac8caca42b03e9079ded41347f4</tree>
  <committer>
    <name>Jakob Heuser</name>
    <email>jakob@felocity.org</email>
  </committer>
</commit>
