Find Jobs
Hire Freelancers

Update RBL check script with DB functions

€30-250 EUR

Completed
Posted over 4 years ago

€30-250 EUR

Paid on delivery
Update RBL check script with DB functions RBL servers are in array $rbls in the script we store them in DB TO DO get them from DB $sql = "SELECT * FROM `rblservers` WHERE `use` = 'true'"; and place it in array get clientnumbers from DB $sqlclientsresult = "SELECT clientnr FROM `clients`"; for each client get ipaddresses to check $ip is in the script now We have a table ipaddress where all IP's are in, get them from table and do rblcheck for each We store the IP as longip $sqlclientsipsresult = "SELECT id, inet_ntoa(longip) as IP FROM `ipaddress` WHERE `clientid` = '" . $rowclients['clientnr'] . "' AND `test` = '1'"; $nu = gmdate($this->dateFormat, time()); Store the scan for the ip listedinrbl is amount of RBL where IP is positive INSERT INTO `rbltests` (`id`, `ipaddressid`, `datetime`, `listedinrbl`) If listed store it rblpositive INSERT INTO `rblpositive` (`ipid`, `rblserverid`, `datetimefirstfound`, `datetimelastfound`, `listed`) INSERT INTO `rblpositive` (`ipid`, `rblserverid`, `datetimefirstfound`, `listed`) VALUES ('1', '8', '$nu', '1') If solved UPDATE `rblpositive` SET `datetimelastfound`='$nu', `listed`='0' This script uses $rev = join('.', array_reverse(explode('.', trim($ip)))); $lookup = sprintf('%s.%s', $rev, $rbl); $listed = gethostbyname($lookup) !== $lookup; for the tests Another solution is: $reversedIP = implode('.', array_reverse(explode ('.', $ip))); // Do the DNS lookup $result = ""; exec("nslookup " . $reversedIP . "." . $value, $result); Please test which works best: fastest versus server load
Project ID: 20826986

About the project

2 proposals
Remote project
Active 5 yrs ago

Looking to make some money?

Benefits of bidding on Freelancer

Set your budget and timeframe
Get paid for your work
Outline your proposal
It's free to sign up and bid on jobs
Awarded to:
User Avatar
Hello there, As discussed in chat, the project is already finished and completed. Looking forward to working on more projects.
€105 EUR in 1 day
5.0 (131 reviews)
6.3
6.3

About the client

Flag of BELGIUM
Brugge, Belgium
5.0
41
Payment method verified
Member since Feb 4, 2008

Client Verification

Thanks! We’ve emailed you a link to claim your free credit.
Something went wrong while sending your email. Please try again.
Registered Users Total Jobs Posted
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Loading preview
Permission granted for Geolocation.
Your login session has expired and you have been logged out. Please log in again.