Solved

A question for Rllibby, maybe some delphi experts can answer

Posted on 2010-11-12
6
938 Views
Last Modified: 2012-05-10
About your firewall code(S), that blocks ip address, web address

The way I test on windows XP?, it's fine.
I test on Windows 7, it's not good.

q1:
iS there a WAY to use the firewall code in windows 7?

q2:
And 1 thing I've see in the code, after blocking a few ip address or web address?, it can't unblock.  (the firewall code(s) that you have distributed has no unblock procedure, isn't it?)


Thanks
0
Comment
Question by:systan
  • 3
  • 3
6 Comments
 
LVL 26

Expert Comment

by:Russell Libby
ID: 34127890
Sorry, not really sure what code you are referring to. There is no code distribution on my site for anything "firewall" related, though I have posted code here regarding IP usage/blocking. If you are referring to code here on EE, please post a link to it. Also keep in mind that anything I wrote in Delphi was done years ago, and before Win7. If its not working now, then I would suggest adding error checking into the code to determine exactly what API calls are failing.

Russell

 
 
0
 
LVL 14

Author Comment

by:systan
ID: 34128124
hi

Does this code don't do unblock? it only blocks? y/n?
http://www.experts-exchange.com/Programming/Languages/Pascal/Delphi/Q_20829690.html#10343841


And also it can't be used in windows 7?
But is there a possible way to use that code for windows 7?
Would you share some steps if it is possible.


Thanks
0
 
LVL 26

Expert Comment

by:Russell Libby
ID: 34128353
1.) The code as written does not handle unblocking. As stated in the original Q, I provided source to add IP filters, but recommended that it be wrapped in a class to allow unblocking, additional functionality, etc. The outbound handle(s) can be obtained in a call to PfAddFiltersToInterface, and then later passed to PfRemoveFilterHandles to remove them.

2.) No, it can't be used in Vista/Win7. This API is deprecated (notice I wrote this 6 1/2 years ago) and is now replaced with the Windows Filtering Platform API:

http://msdn.microsoft.com/en-us/library/Aa364943
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 14

Author Comment

by:systan
ID: 34129499
rllibby?
What are the possible c headers that I WILL convert to Delphi using windows 7 Filtering Platform APi?, just like unit [fltdefs] in windows xp/2003.
0
 
LVL 26

Accepted Solution

by:
Russell Libby earned 125 total points
ID: 34129578

fwpmu.h
fwpmtypes.h


0
 
LVL 14

Author Closing Comment

by:systan
ID: 34130419
Thanks llibby
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Hi friends,  in this video  I'll show you how new windows 10 user can learn the using of windows 10. Thank you.
Many functions in Excel can make decisions. The most simple of these is the IF function: it returns a value depending on whether a condition you describe is true or false. Once you get the hang of using the IF function, you will find it easier to us…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now