Message175990
if a <tr> include two <a> or more,SGMLParser processing has a problem
for example:
<tr>
<td align="center" valign="top" nowrap>
<script language="Javascript">
<!--
if ( 4 == 4 ) document.write("<strong class=\"Critical small\">Critical</strong>");
if ( 4 == 3 ) document.write("<strong class=\"High small\">High</strong>");
if ( 4 == 2 ) document.write("<strong class=\"Medium small\">Medium</strong>");
if ( 4 == 1 ) document.write("<strong class=\"Low small\">Low</strong>");
//-->
</script>
</td>
<td valign="top" align="center" nowrap>
<small><script type="text/javascript">document.write(FormatDate("%d-%b-%y", "2012", "11", "18"));</script></small>
</td>
<td valign="top" align="center" nowrap><small>
<a title="CPAI-2012-809" style="text-transform:uppercase" href="2012/cpai-08-nov.html">
CPAI-2012-809</a></small>
</td>
<td valign="top" nowrap align="center"><small>
<a target="_blank" href="http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2011-2089">CVE-2011-2089</a><br /></small>
</td>
<td valign="top"><small>SCADA ICONICS WebHMI ActiveX Stack Overflow (2011-2089)</small></td>
</tr>
def start_a(self, attrs):
if self.is_td:
cve_href = [v for k, v in attrs if k == "target" and v == "_blank"]
if cve_href:
self.is_a = True
self.is_cve = True
#for SGMLParser maybe have a bug,a <tr> have two <a> has problem
vul_href = [v for k, v in attrs if k == "style"]
print vul_href
if vul_href:
vul_href = "".join([v for k, v in attrs if k == "href"])
if vul_href.find("cve") == -1:
self.href_name = vul_href
else:
self.href_name = ""
here print vul_href but print nothing.Is it ok? |
|
Date |
User |
Action |
Args |
2012-11-20 14:09:36 | moonflow | set | recipients:
+ moonflow |
2012-11-20 14:09:36 | moonflow | set | messageid: <1353420576.69.0.980129168556.issue16513@psf.upfronthosting.co.za> |
2012-11-20 14:09:36 | moonflow | link | issue16513 messages |
2012-11-20 14:09:36 | moonflow | create | |
|