added the last part to the SSN related vuln

This commit is contained in:
Ken Johnson
2013-05-31 13:59:57 -04:00
parent f8e21af3e0
commit 2fa68be920
+17 -2
View File
@@ -27,7 +27,7 @@
<td><%= @user.work_info.income %></td>
<td><%= @user.work_info.bonuses %></td>
<td><%= @user.work_info.years_worked %></td>
<td><%= @user.work_info.SSN %></td>
<td class="ssn"><%= @user.work_info.SSN %></td>
<td><%= @user.work_info.DoB %></td>
</tr>
@@ -38,4 +38,19 @@
</div>
</div>
</div>
</div>
</div>
<script type="text/javascript">
// This should be an EXCELLENT feature!!!
function maskSSN(){
var fullSSN = $("td.ssn").html().replace(/\d{3}.*?\d{2}/, "*****");
$("td.ssn").html(fullSSN);
}
$(document).ready(function () {
maskSSN()
});
</script>