Image and Video Filtering on Internet Networks

Preview:

Citation preview

Image and Video Filtering on Internet Networks

Airlangga Cahya Utama7406.040.006

Background

! Internet as a big source of information

! Not all information is safe to consume

" Example: war, sex, and drugs

! Porn is one of internet problem

! Filter using text based or domain based is difficult to maintain

! SOLUTION: Image or video based filtering

References! Matthew Turk, Alex Pentland, Eigenfaces for

Recognition, 1991

! Muhammad Fatoni Ashariyanto, Rudy Cahyadi Hario Pribadi, Dadet Pramadihanto, Sistem Seleksi Gambar Khusus Dewasa Melalui Web Proxy Menggunakan Image Processing, 2007

Capture Packet

! We can capture packed on computer used to access internet (gateway / hop).

" Transport layer

! nCap, pktd, libpcap

" Application layer

! Proxy (icap protocol)

Transport Layer

! Pro

" Fast

" Didn't need another daemon running

! Cons

" Complicated

" Parsing tcp/ip packet manually

" Combine tcp/ip packet manually, and maintain connection state

Application Layer - ICAP

! Pro

" Simple (based on HTTP)

" Only need to implement ICAP parser

" Can leverage proxy cache capabilities

! Cons

" A bit slow (request is redirected to proxy, more hops)

" Requirement to run proxy daemon

ICAP

! Internet Content Adaptation Protocol (RFC 3507).

! Protocol build to support content adaptation on web-proxy.

! Based and using HTTP format.

! Usage: Virus detection, HTML to WML converter, Content optimizer (image size/text compression), Porn Detection

Squid - ICAP Support

! Squid 3 have built-in ICAP support.

! Squid 3 is already reach mature/stable release

! Squid 2 must be hacked to support ICAP

ICAP Data Example! RESPMOD icap://127.0.0.1:10000/ ICAP/1.0

! Host: 127.0.0.1:10000

! Encapsulated: req-hdr=0, res-hdr=386, res-body=633

! Allow: 204

! GET http://127.0.0.1/logoITS.jpg HTTP/1.1

! Host: 127.0.0.1

! User-Agent: Mozilla/5.0 Gecko/20100611 Firefox/3.6.4

! HTTP/1.1 200 OK

! ???JFIFHHC??(1#%(:3=<9387@H\N@DWE78PmQ

System Overview

ICAP data from Proxy

Image Detection

Image Format Detection

! Parse header data (xx first byte data) from ‘intercepted’ content.

! Why?

" Some server provide dynamic content and tell browser via MIME HTTP Header.

! Example: file image but extension type php

" MIME content can’t be trusted either

! Example: downloadable content

Image Header Example

! PNG File

" 89 50 4E 47 0D 0A 1A 0A – PNG Header

! JPEG File

" FFD8 – Start of image marker

" And followed by another marker such as FFE0, FFDB, FFC4, etc…

Skin Filtering - Peer Model

Requirement:

R>95 && G>40 && B>20 && (max(R,G,B)-min(R,G,B))>15 && abs(R-G)>15

R>G && R>B && G>BR<(G+150) && R<(B+150) && G<(B+150)

Result Example of Skin Filtering

Method Used to Detect Object

! Haar Wavelet

" Rainer Lienhart, Alexander Kuranov, Vadim Pisarevsky

! Eigenfaces

" Matthew Turk, Alex Pentland

Object Detection Haar Wavelet

Haar Wavelet

Eigenfaces – Training Algorithm! Concate Images

! Find mean

! Find image mean

! Build A from image mean

! Find matrix covariant C

! Find eigenvector from C

! Keep some eigenvector with the highest eigenvalue

Eigenfaces – Training Data

Eigenfaces – Compare Algorithm! Find weight, from

calculation with eigenvector.

! Projection image to facespaces.

! Measure distance between image and facespaces.

! Compare distance and threshold

Scanning Method

! Take a 64x64 slice from image

! Compare it

! Move to the next slice

! If all slice checked, resize image to smaller one with nearest neighborhood method

! Move distance is 24 pixel, scale down is 15% ratio.

Responding to Proxy

Networking Result

Networking Result

Result (Detected - Change Image)

Result (Not Detected)

Result (Detected and Not-Detected)

Object Detection

Testing

! 200 positive image

" Variation of size

" Variation or colour skin

" All frontal and contain breast object

! 410 negative image

" Variation of size

" Variation of image object

! page banner, thumbnail, and people

Detection Rate

Detection Rate

Performance

Conclusion

! ICAP filtering method is proved working corectly.

! Eigenfaces speed is comparable to Haar Wavelet.

! Eigenfaces detection is worse than Haar.

! Buffering technique is working only for non-streaming website.

Image and Video Filtering on Internet Networks

END

Recommended