Script late injection: a framework to introduce JavaScript into web pages

Bhanu Prakash, Sandhya Sampangiramaiah
{"title":"Script late injection: a framework to introduce JavaScript into web pages","authors":"Bhanu Prakash, Sandhya Sampangiramaiah","doi":"10.11591/ijra.v13i1.pp96-104","DOIUrl":null,"url":null,"abstract":"Script injection is one type of fault present in web, which mostly utilizes user data to execute code without applying any type of filters. Script injection can impact both client and server making exposing them to vulnerabilities. Security and related products may need to execute logic on the client-side generally in a browser. In order to achieve this, proxy servers inject appropriate JavaScript code into the responses they proxy. Typically, the injection point is at the end of the body element. The framework introduced in this paper rather uses a stack-based approach to determine the injection point in the web page. Ten kilobytes from the end of a web page are given as a string input to the framework, after tokenization and construction of the vector of tokens. A stack is used to determine the injection point. Along with the position of the injection point, a warning flag is also estimated indicating the correctness of the injection point. Different types of web pages were considered for running the unit tests and fuzzy tests on the framework. These classes of pages are determined by crawling most used web pages. The injected scripts are executed once the body content is completely loaded. Hence, it can retrieve maximum information without affecting end-user performance. It also does the job at a low cost.","PeriodicalId":422370,"journal":{"name":"IAES International Journal of Robotics and Automation (IJRA)","volume":"23 15","pages":""},"PeriodicalIF":0.0000,"publicationDate":"2024-03-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"IAES International Journal of Robotics and Automation (IJRA)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.11591/ijra.v13i1.pp96-104","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

Script injection is one type of fault present in web, which mostly utilizes user data to execute code without applying any type of filters. Script injection can impact both client and server making exposing them to vulnerabilities. Security and related products may need to execute logic on the client-side generally in a browser. In order to achieve this, proxy servers inject appropriate JavaScript code into the responses they proxy. Typically, the injection point is at the end of the body element. The framework introduced in this paper rather uses a stack-based approach to determine the injection point in the web page. Ten kilobytes from the end of a web page are given as a string input to the framework, after tokenization and construction of the vector of tokens. A stack is used to determine the injection point. Along with the position of the injection point, a warning flag is also estimated indicating the correctness of the injection point. Different types of web pages were considered for running the unit tests and fuzzy tests on the framework. These classes of pages are determined by crawling most used web pages. The injected scripts are executed once the body content is completely loaded. Hence, it can retrieve maximum information without affecting end-user performance. It also does the job at a low cost.
脚本后期注入:将 JavaScript 引入网页的框架
脚本注入是网络中存在的一种故障,它主要利用用户数据来执行代码,而不应用任何类型的过滤器。脚本注入会影响客户端和服务器,使其面临漏洞。安全和相关产品可能需要在客户端(通常是浏览器)执行逻辑。为此,代理服务器会在其代理的响应中注入适当的 JavaScript 代码。通常,注入点位于 body 元素的末尾。本文介绍的框架采用基于堆栈的方法来确定网页中的注入点。在标记化和构建标记向量后,将网页末尾的 10 千字节作为字符串输入框架。堆栈用于确定注入点。在确定注入点位置的同时,还估算出一个警告标志,表明注入点的正确性。在框架上运行单元测试和模糊测试时,考虑了不同类型的网页。这些网页类别是通过抓取最常用的网页确定的。注入的脚本会在主体内容完全加载后执行。因此,它可以在不影响终端用户性能的情况下检索到最多的信息。它还能以较低的成本完成工作。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
CiteScore
0.40
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:604180095
Book学术官方微信
小红书