/    Sign up×
Community /Pin to ProfileBookmark

Loading HTML page dynamically

Hey,

I’m checking out the tabnabbing browser attack, and came across this page:

[url]http://www.azarask.in/blog/post/a-new-type-of-phishing-attack/[/url]

there, you can see an example of the attack by opening it in a tab, and switching over to another tab for a few seconds. what will happen is it will change the favicon, title and the page to an image with this script:

[url]http://www.azarask.in/projects/bgattack.js[/url]

Once you click it, the page will go back to normal (just a demo).

My question is, how would I go about making the function createShield() load an html page and change the whole page, instead of loading just an image?

I would like to do this without redirecting to another page.

Thanks!

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@Angry_Black_ManApr 06.2012 — AJAX could "load an html page". regular javascript can then be used to "change the whole page".

here's the AJAX tutorial:

http://www.w3schools.com/ajax/default.asp

the idea here would be that instead of loading a TXT file, you'd load some HTML file. then, you'd have to write the contents of the HTML file to the page.

all without redirecting to another page.
×

Success!

Help @whatwhenwho spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.22,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...