From b10c4b3d3a52bb691cad220419de64f87eac9bc1 Mon Sep 17 00:00:00 2001 From: Jordan Wright Date: Fri, 18 Mar 2016 23:35:07 -0500 Subject: [PATCH] Now returning valid tracking image. Fixes #202 --- controllers/route.go | 4 ++-- static/images/pixel.png | Bin 0 -> 95 bytes 2 files changed, 2 insertions(+), 2 deletions(-) create mode 100644 static/images/pixel.png diff --git a/controllers/route.go b/controllers/route.go index e95f63ed..5f350238 100644 --- a/controllers/route.go +++ b/controllers/route.go @@ -113,7 +113,7 @@ func PhishTracker(w http.ResponseWriter, r *http.Request) { // Don't update the status if the user already clicked the link // or submitted data to the campaign if rs.Status == models.STATUS_SUCCESS { - w.Write([]byte("")) + http.ServeFile(w, r, "static/images/pixel.png") return } err = rs.UpdateStatus(models.EVENT_OPENED) @@ -134,7 +134,7 @@ func PhishTracker(w http.ResponseWriter, r *http.Request) { if err != nil { Logger.Println(err) } - w.Write([]byte("")) + http.ServeFile(w, r, "static/images/pixel.png") } // PhishHandler handles incoming client connections and registers the associated actions performed diff --git a/static/images/pixel.png b/static/images/pixel.png new file mode 100644 index 0000000000000000000000000000000000000000..1914264c08781d1f30ee0b8482bccf44586f2dc1 GIT binary patch literal 95 zcmeAS@N?(olHy`uVBq!ia0vp^j3CU&3?x-=hn)ga%mF?ju0VQumF+E%TuG2$FoVOh l8)-lem#2$k2*>s01R$Gz9%CSj!PC{xWt~$(697H@6ZHT9 literal 0 HcmV?d00001