Author Topic: wrc-script-middle_window  (Read 10375 times)

0 Members and 1 Guest are viewing this topic.

quimfv

  • Guest
wrc-script-middle_window
« on: February 27, 2012, 10:46:55 AM »
I get this script is AVAST who introduces it?

In reviewing a personal project I have seen this code (attached header functions) in the head (head), to inspect fire bug or the equivalent of chrome. First I thought of the libraries I use in the project but then I realized that appears on every page I visit.

<style id="wrc-middle-css" type="text/css">
 
....css rules....
 
</style>
 
<script id="wrc-script-middle_window" type="text/javascript" language="JavaScript">
var g_inputsCnt = 0;
var g_InputThis = new Array(null, null, null, null);
var g_alerted = false;
/* we test the input if it includes 4 digits (input is a part of 4 inputs for filling the credit-card number)*/
function is4DigitsCardNumber(val){
...
    }
/* testing the whole credit-card number 19 digits devided by three '-' symbols or exactly 16 digits without any dividers*/
function isCreditCardNumber(val){
...
}
function CheckInputOnCreditNumber(self){
...
}
function CheckInputOnPassword(self){
...
    }
 
function onInputBlur(self, bRatingOk, bFishingSite){
...
}
</script>

Disabling browser protection of AVAST (I use the free version and is updated) seems to disappear.

Since the function names are a minimum alarming, I am looking for documentation on the subject.

In the css seems to create a hidden frame.

You have information?, AVAST is really who enter this code?

If so be not you think it would be a help to sign, at least one comment ...


Thanks in advance

Quim
« Last Edit: February 27, 2012, 02:19:56 PM by quimfv »

meishern

  • Guest
Re: wrc-script-middle_window
« Reply #1 on: March 02, 2012, 05:22:04 PM »
I have the same problem. I have weird code being injected . PLEASE RESPOND.

<style id="wrc-middle-css" type="text/css">.wrc_whole_window{   display: none;   position: fixed;    z-index: 2147483647;   background-color: rgba(40, 40, 40, 0.9);   word-spacing: normal;   margin: 0px;   padding: 0px;   border: 0px;   left: 0px;   top: 0px;   width: 100%;   height: 100%;   line-height: normal;   letter-spacing: normal;}.wrc_middle_main {   font-family: Segoe UI, Arial Unicode MS, Arial, Sans-Serif;   font-size: 14px;   width: 600px;   height: auto;   margin: 0px auto;   margin-top: 15%;    background: url(chrome-extension://icmlaeflemplmjndnaapfdbbnpncnbda/skin/images/background-body.jpg) repeat-x left top;   background-color: rgb(39, 53, 62);}.wrc_middle_logo {    background: url(chrome-extension://icmlaeflemplmjndnaapfdbbnpncnbda/skin/images/logo.jpg) no-repeat left bottom;    width: 140px;    height: 42px;    color: orange;    display: table-cell;    text-align: right;    vertical-align: middle;}.wrc_icon_warning {   margin: 20px 10px 20px 15px;   float: left;   background-color: transparent;}.wrc_middle_title {    color: #b6bec7;   height: auto;    margin: 0px auto;   font-size: 2.2em;   white-space: nowrap;   text-align: center;}.wrc_middle_hline {    height: 2px;   width: 100%;    display: block;}.wrc_middle_description {   text-align: center;   margin: 15px;   font-size: 1.4em;   padding: 20px;   height: auto;   color: white;   min-height: 3.5em;}.wrc_middle_actions_main_div {   margin-bottom: 15px;   text-align: center;}.wrc_middle_actions_blue_button {   -moz-appearance: none;   border-radius: 7px;   -moz-border-radius: 7px/7px;   border-radius: 7px/7px;   background-color: rgb(0, 173, 223) !important;   display: inline-block;   width: auto;   cursor: Pointer;   border: 2px solid #00dddd;}.wrc_middle_actions_blue_button:hover {   background-color: rgb(0, 159, 212) !important;}.wrc_middle_actions_blue_button:active {   background-color: rgb(0, 146, 200) !important;   border: 2px solid #00aaaa;}.wrc_middle_actions_blue_button div {   display: inline-block;   width: auto;   cursor: Pointer;   margin: 3px 10px 3px 10px;   color: white;   font-size: 1.2em;   font-weight: bold;}.wrc_middle_action_low {   font-size: 0.9em;   white-space: nowrap;   cursor: Pointer;   color: grey !important;   margin: 10px 10px 0px 10px;   text-decoration: none;}.wrc_middle_action_low:hover {   color: #aa4400 !important;}.wrc_middle_actions_rest_div {   padding-top: 5px;   white-space: nowrap;   text-align: center;}.wrc_middle_action {   white-space: nowrap;   cursor: Pointer;   color: red !important;   font-size: 1.2em;   margin: 10px 10px 0px 10px;   text-decoration: none;}.wrc_middle_action:hover {   color: #aa4400 !important;}</style><script id="wrc-script-middle_window" type="text/javascript" language="JavaScript">var g_inputsCnt = 0;var g_InputThis = new Array(null, null, null, null);var g_alerted = false;/* we test the input if it includes 4 digits   (input is a part of 4 inputs for filling the credit-card number)*/function is4DigitsCardNumber(val){   var regExp = new RegExp('[0-9]{4}');   return (val.length == 4 && val.search(regExp) == 0);}/* testing the whole credit-card number 19 digits devided by three '-' symbols or   exactly 16 digits without any dividers*/function isCreditCardNumber(val){   if(val.length == 19)   {      var regExp = new RegExp('[0-9]{4}-[0-9]{4}-[0-9]{4}-[0-9]{4}');      return (val.search(regExp) == 0);   }   else if(val.length == 16)   {      var regExp = new RegExp('[0-9]{4}[0-9]{4}[0-9]{4}[0-9]{4}');      return (val.search(regExp) == 0);   }   return false;}function CheckInputOnCreditNumber(self){   if(g_alerted)      return false;   var value = self.value;   if(self.type == 'text')   {      if(is4DigitsCardNumber(value))      {         var cont = true;         for(i = 0; i < g_inputsCnt; i++)            if(g_InputThis == self)               cont = false;         if(cont && g_inputsCnt < 4)         {            g_InputThis[g_inputsCnt] = self;            g_inputsCnt++;         }      }      g_alerted = (g_inputsCnt == 4);      if(g_alerted)         g_inputsCnt = 0;      else         g_alerted = isCreditCardNumber(value);   }   return g_alerted;}function CheckInputOnPassword(self){   if(g_alerted)      return false;   var value = self.value;   if(self.type == 'password')   {      g_alerted = (value.length > 0);   }   return g_alerted;}function onInputBlur(self, bRatingOk, bFishingSite){   var bCreditNumber = CheckInputOnCreditNumber(self);   var bPassword = CheckInputOnPassword(self);   if((!bRatingOk || bFishingSite == 1) && (bCreditNumber || bPassword) )   {      var warnDiv = document.getElementById("wrcinputdiv");      if(warnDiv)      {         /* show the warning div in the middle of the screen */         warnDiv.style.left = "0px";         warnDiv.style.top = "0px";         warnDiv.style.width = "100%";         warnDiv.style.height = "100%";         document.getElementById("wrc_warn_fs").style.display = 'none';         document.getElementById("wrc_warn_cn").style.display = 'none';         if(bFishingSite)            document.getElementById("wrc_warn_fs").style.display = 'block';         else            document.getElementById("wrc_warn_cn").style.display = 'block';         warnDiv.style.display = 'block';      }   }}</script></head>
<body>

Offline Pondus

  • Probably Bot
  • ****
  • Posts: 37547
  • Not a avast user
Re: wrc-script-middle_window
« Reply #2 on: March 02, 2012, 05:29:23 PM »
@meishern

start your own topic and explain the problem 

quimfv

  • Guest
Re: wrc-script-middle_window
« Reply #3 on: March 05, 2012, 01:11:18 PM »
Do you have documentation about?

Offline bob3160

  • Avast Überevangelist
  • Probably Bot
  • *****
  • Posts: 48595
  • 64 Years of Happiness
    • bob3160 Protecting Yourself, Your Computer and, Your Identity
Re: wrc-script-middle_window
« Reply #4 on: March 05, 2012, 02:26:55 PM »
Do you have documentation about?
If you do, please also include that in your own post.
Free Security Seminar: https://bit.ly/bobg2023  -  Important: http://www.organdonor.gov/ -- My Web Site: http://bob3160.strikingly.com/ - Win 11 Pro v24H2 64bit, 32 Gig Ram, 1TB SSD, Avast Free 24.4.6112, How to Successfully Install Avast http://goo.gl/VLXdeRepair & Clean Install https://goo.gl/t7aJGq -- My Online Activity https://bit.ly/BobGInternet

k.u.r.t

  • Guest
Re: wrc-script-middle_window
« Reply #5 on: March 06, 2012, 10:05:04 AM »
In order for the WebRep plugin to work it needs to inject CSS and JavaScript code into the webpages. WRC is the original internal codename that later became WebRep.

Offline srajer

  • Avast team
  • Newbie
  • *
  • Posts: 5
Re: wrc-script-middle_window
« Reply #6 on: March 06, 2012, 10:34:25 AM »
Mentioned code is injected by avast plugin. It is the part of anti-phising filter.

REDACTED

  • Guest
Re: wrc-script-middle_window
« Reply #7 on: July 08, 2014, 07:16:30 AM »
We need to know how to disable this, turning phishing off didn't change a thing for me and I'd prefer to keep that feature active...it just needs to be built smarter.

It's injecting code into my sites while I develop them which makes it difficult to determine what is my css and what is not.  i.e. all external urls have extra nbsp spaces and spans injected right inside my blocks of code thus pushing elements, forcing wraps, adding extra margin/padding and line heights, etc. (different for each browser)  Learn how to use overlays with position absolute instead please.  Do it the proper way.