PDA


View Full Version : Block Request


tomshawk
07-26-2004, 02:01 AM
Hello Everyone.

I really dont see a place for requests so...

I'll drop it in here

I used to run a phpnuke site, and I had a really kewl block that someone created for me. for Symantec's Latest Virus threats

Sence I moved to vBulletin and could not use it, I never bothered asking before

A friend of mine is running it here http://www.securelyspeaking.com/ so you can see it. It is the block on the left side that just says Symantec

It was modified once by some people over at vbPortal for vbPortal obviously. I have that to if you want it.

but, I am not running vbPortal, I was wondering if any of you here would like to take a stab at it for vbAdvanced.

Before you ask, I dont like the sophos or the one that Symantec offers from there site.

I am attaching a zip file withe the php file the phpnuke instructions and the cache file. It should hopefully give you an idea of where to start.

Thanks to anyone that decides to try this

tomshawk
07-27-2004, 10:55 PM
I think I threw this in the wrong forum. Can someone move it, Please!!

None-the-less any ideas?

KW802
07-27-2004, 11:24 PM
Tomshawk, here's one....

http://www.vbadvanced.com/forum/showthread.php?t=880

tomshawk
07-28-2004, 12:33 AM
Thank you again Kevin

As I said in the first post, I dont like the sophos one or the one that Symantec offers.

It looks just like the one on Symantec's site in that it uses the on and off red threat level numbers. Plus, This one is much more basic and to the point.

Thank you though.

I see no one has even downloaded it. could someone try please. Sorry, I wish I was a programmer, I'd do it myself. but... I'm not, Hardly even.

Thank you for your time

KW802
07-28-2004, 12:42 AM
As I said in the first post, I dont like the sophos one or the one that Symantec offers.
Whoops.... I went to the example URL you gave but missed the blurb that you don't like the canned Symantec one. :p

tomshawk
07-28-2004, 12:45 AM
Whoops.... I went to the example URL you gave but missed the blurb that you don't like the canned Symantec one. :p
No worries ;)

Thank you for looking after me :p

KW802
07-28-2004, 01:04 AM
Interesting code.... the PHP is using HTTP to do a screen-scrape directly from the Symantec site which is good & bad. It's good in that it should be able to be modified but bad in that if Symantec changes that one page then the code to scrape becomes useless unless it's modified to handle the revised page. Assuming that you've already looked at the code... the part that has the phrase "LATEST THREATS LIST start" is the marker of where it'll start grabbing the code from the Symantec page and the "LATEST THREATS LIST end" is where it stops; below that then is the code to replace the instances of "/avcenter" from being local to the Symantec server to instead be hard-coded to the full Symantec URL ("http://securityresponse.symantec.com/avcenter"). The code that deals with the cache is beyond me (I'm just a PHP idiot).

Are you sure really want this version? It really would be taking a chance in assuming that Symantec is never going to change their HTML code on that page.

tomshawk
07-28-2004, 01:15 AM
well, I have been using that site for, J33Z, 8 years at least, and it looks the same now as it did then :p

So, chances are pretty good it wont change ;)

I'd love to give it a try though

KW802
07-28-2004, 02:12 AM
Tomshawk,

I think I got it.... http://www.farpointstation.org/index.php?page=testing&styleid=12

Give me a minute to post the PHP file....

tomshawk
07-28-2004, 02:15 AM
Tomshawk,

I think I got it.... http://www.farpointstation.org/index.php?page=testing&styleid=12

Give me a minute to post the PHP file....
Dude, You rock!!!

http://www.tomshawk.com/forums/images/smilies/musicband.gif http://www.tomshawk.com/forums/images/smilies/banana.gif http://www.tomshawk.com/forums/images/smilies/icon_beer.gif

KW802
07-28-2004, 02:28 AM
OK, the stuff about the cache file was throwing me off until I realized it was nothing more than a plain text file that was being used to store the results locally rather than hitting the remote server every single time.

1. Create a template. I called mine "adv_portal_testing" and here's the code (I think we all know this generic shell by now by heart :p ).....
<table align="center" border="0" cellpadding="$stylevar[cellpadding]" cellspacing="$stylevar[cellspacing]" class="tborder" width="100%">

<tr>
<td class="tcat">
<span class="smallfont">
<strong>$vba_options[portal_blockbullet] $mods[title]</strong>
</span>
</td>
</tr>

<tr><td class="$getbgrow" width="100%">$content</td></tr>
</table>
<br />

2a. Modify the attached PHP file so that line #29 reflects where you are planning on putting the cache file. Example....$cache_file = "/home/farpointstation/www/forums/modules/sym.cache"; # Your cache directory

2b. Modify the PHP file so that line #86 reflects the template name that you used in step #1. Example....eval('$home[$mods[\'modid\']][\'content\'] = "' . fetch_template('adv_portal_testing') . '";');

3. Upload the sym.cache file from the original zip to the location you specified in step #2a. Remember to CHMOD the permissions to either 777 or 766.

4. Upload the modified PHP file to your modules folder.

5. Create a new module and insert on your page as desired. Use the modified PHP file and don't forget to reference the template name.

That's it, you're done. Don't be alarmed if the first time you view the page you see different results then what's on the Symantec page; it's the contents of the cache file. Just wait a few minutes and then refresh your page and the cache should then get updated (make sure you refresh).


If you have problems track me down around lunch time tommorrow; it's nearly 1:30am EST and my fiance is going to kill me if I don't finish up some paperwork for her side business. :eek:

tomshawk
07-28-2004, 03:40 AM
Thank you Sir.

Works perfectly ;)

At least until time to refresh, lets see if it still works then :p

Actually the cache file is updating so it should not be an issue ;)

Thanks again, I owe you one