Featured post

c# - Usage of Server Side Controls in MVC Frame work -

i using asp.net 4.0 , mvc 2.0 web application. project requiremrnt have use server side control in application not possibl in noraml case. ideally want use adrotator control , datalist control. i saw few samples , references in codepleax mvc controllib howwver found less useful. can tell how utilize theese controls in asp.net application along mvc. note: please provide functionalities related adrotator , datalist controls not equivalent functionalities thanks in advace. mvc pages not use normal .net solution makes use of normal .net components impossible. a normal .net page use event driven solution call different methods service side mvc use actions , view completly different way handle things. also, mvc not use viewstate normal .net controlls require. found article discussing mixing of normal .net , mvc.

networking - How to monitor my network connection with Java? -


is there sample code can report url pc connecting java?

while use browser connect different sites , watch video online, should capture urls. doable in java?

i don't want detailed traffic, record urls.

the fastest way going to capture output of command-line tshark program (for @ least windows , linux). works on linux box:

sudo tshark -f 'port 80' -r 'http' -v | grep -a 1 '^hypertext transfer protocol' 

and produces output like:

running user "root" , group "root". dangerous. capturing on eth0 hypertext transfer protocol     /questions/4494294/r-gplots-barplots-how-to-fix-bar-width-independent-of-paper-setting http/1.1\r\n -- hypertext transfer protocol     http/1.1 200 ok\r\n -- hypertext transfer protocol     /posts/4494294/ivc/086e http/1.1\r\n -- hypertext transfer protocol     http/1.1 204 no content\r\n -- hypertext transfer protocol     [truncated] /__utm.gif?utmwv=4.8.6&utmn=20455052&utmhn=stackoverflow.com&utmcs=utf-8&utmsr=1600x1200&utmsc=24-bit&utmul=en-us&utmje=1&utmfl=10.1%20r102&utmdt=graph%20-%20r%3a%20gplots%2c%20barplots%3a%20how%20to%20fix%20bar%20width%20i -- hypertext transfer protocol     http/1.1 200 ok\r\n -- 

you should similar windows. experiment. how output of tshark java you.

if want all-java solution, how http://jnetpcap.com/ ?

you're going have write (or use library provides) platform specific jni code.

libpcap/winpcap jnetpcap uses provides reliably on @ least windows , linux experience. have experience libpcap/winpcap not jnetpcap.

tshark uses libpcap/winpcap actually.

either way, you're going see many false positives. opening html page requires getting many, many images, style sheets, javascript libraries etc. snippet above opening stackoverflow.com page.


Comments

Popular posts from this blog

c# - Usage of Server Side Controls in MVC Frame work -

cocoa - Nesting arrays into NSDictionary object (Objective-C) -

ios - Very simple iPhone App crashes on UILabel settext -