{"_id":"@antv/vis-steg","_rev":"35-ec5b0bc882e5623f9303a9487cfb30d2","name":"@antv/vis-steg","dist-tags":{"latest":"0.1.0-alpha.1"},"versions":{"0.1.0-alpha.1":{"name":"@antv/vis-steg","version":"0.1.0-alpha.1","author":{"url":"https://antv.vision/","name":"AntV"},"license":"MIT","_id":"@antv/vis-steg@0.1.0-alpha.1","maintainers":[{"name":"intchous","email":"h.a.p.p.y.y.x.d@163.com"},{"name":"soundquiet","email":"fulingsun515@gmail.com"},{"name":"lviser","email":"liuvigongzuoshi@gmail.com"},{"name":"freestyle21","email":"675861708@qq.com"},{"name":"serializedowen","email":"wjh199455@gmail.com"},{"name":"sturuby","email":"xingya.shi@gmail.com"},{"name":"xdzhao","email":"zhaoxiaodong@zju.edu.cn"},{"name":"elaine.q.10","email":"yilin.qyl@antfin.com"},{"name":"sakuya223","email":"360965398@qq.com"},{"name":"leungwensen","email":"leungwensen@gmail.com"},{"name":"dori","email":"418466938@qq.com"},{"name":"simaq","email":"sima.zhang1990@gmail.com"},{"name":"dxq613","email":"dxq613@gmail.com"},{"name":"lzxue","email":"120635640@qq.com"},{"name":"army8735","email":"army8735@qq.com"},{"name":"atool","email":"i@hust.cc"},{"name":"baizn","email":"576375879@qq.com"},{"name":"dengfuping","email":"dengfuping_develop@163.com"},{"name":"neoddish","email":"neoddish@outlook.com"},{"name":"jeffy2012","email":"yuanjiefeng@gmail.com"},{"name":"zqlu","email":"zqlu.cn@gmail.com"},{"name":"afc163","email":"afc163@gmail.com"},{"name":"pomelo-nwu","email":"czynwu@gmail.com"},{"name":"kopiluwaky","email":"yanyanwang93@gmail.com"},{"name":"ccnuzindex","email":"ccnuzindex@gmail.com"},{"name":"panyuqi","email":"pyqiverson@gmail.com"},{"name":"bubkoo","email":"bubkoo.wy@gmail.com"},{"name":"zengyue","email":"yezengyue@gmail.com"},{"name":"kasmine","email":"736929286@qq.com"},{"name":"boyu.zlj","email":"boyu.zlj@antfin.com"},{"name":"l1ud0ngq1","email":"lliudongqi@gmail.com"},{"name":"newbyvector","email":"vectorse@126.com"},{"name":"winniexing","email":"wanyingxing@gmail.com"},{"name":"chenluli","email":"chenluuli@gmail.com"},{"name":"kn9117","email":"1175863618@qq.com"},{"name":"xdddst","email":"deng25st@163.com"},{"name":"semious2020","email":"semious@163.com"},{"name":"esora","email":"tygyh2012@gmail.com"},{"name":"nadia_liu","email":"1803275951@qq.com"},{"name":"bbsqq","email":"1491812683@qq.com"},{"name":"mxz96102","email":"mxz96102@qq.com"},{"name":"openwayne","email":"openwayne@gmail.com"},{"name":"pearmini","email":"subairui@icloud.com"},{"name":"pddpd","email":"pddpengdi@gmail.com"},{"name":"yiqianyao","email":"2912401452@qq.com"},{"name":"zhanba","email":"c5e1856@gmail.com"},{"name":"cxxxxxn","email":"christy05.chen@gmail.com"}],"homepage":"https://antvis.github.io/vis-steg","bugs":{"url":"https://github.com/antvis/vis-steg/issues"},"dist":{"shasum":"a65bc079322a923dad33c3a76ce7faded30bf1bc","tarball":"https://registry.npmjs.org/@antv/vis-steg/-/vis-steg-0.1.0-alpha.1.tgz","fileCount":49,"integrity":"sha512-tubvh2rU3rIJ2TdeC61zjRvN0wKKN7GMsUInR+/E35dkF8bhYAFDCbQbTS19VB/nL4VMaoOZNdr6Z0947xS4Bw==","signatures":[{"sig":"MEUCIQCl7fYB1h/nsWuEXVOZdr7NLAcJ1hv2pipqnE7/GSdPbwIgDqy+qMF4XX3CADKF9t4EG6GQ/KXj1qtTS60Z+heRLBk=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":112690,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJh11poCRA9TVsSAnZWagAAjrsP/3TIEzN/w8kmwhnR4XbU\nR4Aa2BaWKBVucAsk85HtKvyT1q2Gxsuh0S+EsNAQH1FhWkUJhzdiumxHDoU8\neOenawN2BIOCl6X8VMnwg9J19Gx7a4hFBPIN5UwYEAhdv43El/bEF2kSXFLh\nJmjr73YdLd3gCiLcun4F1f8M13fksdZ2OH/cF1qQka3mn2SULw2wuEq1AA2M\nAw1/bwByXr5hAo1bP0IZyWO9mWimbPfXbW529W165FcAonpdx6pGza6l4YTA\n9sDf0Rhaw+3ZKu2b1tQoJWMPlVQ4JqwWAf6YAvsSdhF1tOYdJX8UQoj7iKf0\nENoFhRXAA4/VyUKH5RZyTkeNGlgs1HS5TPucyXgwaRy3mCn25gv0HGqGLS9s\nkM9ehkAFt5qYdV0vQs5nlB1TPIdQ3FKFE2ELFx6cZrzLF7GiSmvj5IQNwmlW\n3/bO17k3p1ZCRkMjCtbMbo18M0HZNJ9OXKc9mmbsrUlvdxU1TSI1rV3MCqcU\nDB2QBg+R01yOEKyjTstb0Qe/CCWbCghOaOLBc8OgQ4ErABCcyiOZBMBYDcAi\nkQjFxFFYbmKwV1/UEibsk2inrosHrtp+Mg6u6aGrUlSWVzpkD9dQh2hbpH6q\nMbowaCGSoqnE2kAqTwU1IEY/BkqkFLgrlnpRqB1VM7CU3G2WOrYJ0ZIyBVMc\nKtND\r\n=qdD6\r\n-----END PGP SIGNATURE-----\r\n"},"main":"lib/index.js","types":"lib/index.d.ts","unpkg":"dist/index.min.js","module":"esm/index.js","gitHead":"44b000d6386881f73f92cb92dcdd1293c140d0a0","scripts":{"ci":"run-s lint test build","fix":"eslint ./src/**/*.ts ./__tests__/**/*.ts ./demo/**/*.{ts,tsx} --fix && npm run format","lint":"eslint ./src/**/*.ts ./__tests__/**/*.ts ./demo/**/*.{ts,tsx} && npm run format-check","size":"limit-size","test":"jest","build":"run-p build:*","clean":"rimraf lib esm dist","format":"prettier --write \"src/**/*.ts\" \"__tests__/**/*.ts\" \"demo/**/*.{ts,tsx}\"","prepare":"husky install","build:cjs":"rimraf ./lib && tsc --module commonjs --outDir lib","build:esm":"rimraf ./esm && tsc --module ESNext --outDir esm","build:umd":"rimraf ./dist && rollup -c && npm run size","start:demo":"cd demo && npm install && npm start","deploy:site":"cd demo && npm run deploy:site","lint-staged":"lint-staged","format-check":" prettier ./src/**/*.ts ./__tests__/**/*.ts ./demo/**/*.{ts,tsx} --check","prepublishOnly":"npm run ci"},"_npmUser":{"name":"intchous","email":"h.a.p.p.y.y.x.d@163.com"},"limit-size":[{"gzip":true,"path":"dist/index.min.js","limit":"8 Kb"},{"path":"dist/index.min.js","limit":"24 Kb"}],"repository":{"url":"git+https://github.com/antvis/vis-steg.git","type":"git"},"_npmVersion":"6.14.13","description":"Visualization Steganography: conceal information within visualization images.","directories":{},"lint-staged":{"*.{ts,tsx}":["eslint --fix","prettier --write","git add"]},"_nodeVersion":"14.17.0","dependencies":{"jsqr":"^1.4.0","pica":"^7.1.0","qrcode":"^1.4.4"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"jest":"^26.6.3","husky":"^6.0.0","eslint":"^7.29.0","rimraf":"^3.0.2","rollup":"^2.52.4","ts-jest":"^26.5.4","prettier":"^2.3.1","limit-size":"^0.1.4","typescript":"4.3.5","@types/jest":"^26.0.22","lint-staged":"^11.0.0","npm-run-all":"^4.1.5","style-loader":"^2.0.0","@babel/runtime":"^7.13.10","@commitlint/cli":"^12.1.4","eslint-plugin-react":"^7.24.0","eslint-config-airbnb":"^18.2.1","eslint-plugin-import":"^2.23.4","rollup-plugin-uglify":"^6.0.4","eslint-config-prettier":"^8.3.0","eslint-plugin-prettier":"^3.4.0","@rollup/plugin-typescript":"^8.2.1","@typescript-eslint/parser":"^4.27.0","@rollup/plugin-node-resolve":"^13.0.0","@commitlint/config-conventional":"^12.1.4","@typescript-eslint/eslint-plugin":"^4.27.0","eslint-import-resolver-typescript":"^2.4.0"},"_npmOperationalInternal":{"tmp":"tmp/vis-steg_0.1.0-alpha.1_1630656120941_0.7122550011439341","host":"s3://npm-registry-packages"}}},"time":{"created":"2021-09-03T08:02:00.860Z","modified":"2026-09-21T08:46:55.700Z","0.1.0-alpha.1":"2021-09-03T08:02:01.071Z"},"bugs":{"url":"https://github.com/antvis/vis-steg/issues"},"author":{"url":"https://antv.vision/","name":"AntV"},"license":"MIT","homepage":"https://antvis.github.io/vis-steg","repository":{"url":"git+https://github.com/antvis/vis-steg.git","type":"git"},"description":"Visualization Steganography: conceal information within visualization images.","maintainers":[{"email":"yunji.me@outlook.com","name":"lvisei"},{"email":"943720372@qq.com","name":"iaaron"},{"email":"jinke.li666@gmail.com","name":"jinke.li"},{"email":"120635640@qq.com","name":"lzxue"},{"email":"army8735@qq.com","name":"army8735"},{"email":"dengfuping_private@163.com","name":"dengfuping"},{"email":"afc163@gmail.com","name":"afc163"},{"email":"chenluuli@gmail.com","name":"chenluli"},{"email":"1175863618@qq.com","name":"kn9117"},{"email":"1491812683@qq.com","name":"bbsqq"},{"email":"zhuyuxin0627@gmail.com","name":"banxuan"},{"email":"ojh496845051@gmail.com","name":"yanxiong"},{"email":"wzwahl36@qq.com","name":"atool"},{"email":"610999886@qq.com","name":"pearl_wang"},{"email":"787982239@qq.com","name":"interstellarmt"},{"email":"alex_zjt@163.com","name":"alex_zjt"},{"email":"duxinyue.dxy@antgroup.com","name":"duxinyue023"},{"email":"mrwang1212@126.com","name":"wang1212"},{"email":"gaofh1023@163.com","name":"gaofuhong"}],"readme":"<h1 align=\"center\">\n<b>@antv/vis-steg</b>\n</h1>\n\n<div align=\"center\">\nVisualization Steganography: conceal information within visualization images.\n</div>\n\n## ✨ Features\n\n- **Information Encoding and Decoding**: A javascript library for embedding information within visualization images.\n  The decoding algorithm just relys on the encoded image.\n- **String and Bits Array Transformation**: Converting a string to a bits array and vice versa using UTF8 encoding and decoding.\n\n- **QR Code for Error Correction**: Add QR code as error correction code before encoding and after decoding.\n\n## 📦 Installation\n\n```bash\n$ npm install\n```\n\n## 🔨 Getting Started\n\n**Basic use**\n\n- Information Encoding\n\n```ts\nimport { LSBSteg } from './src';\n\nconst testLSBSteg = new LSBSteg();\nconst secretInfo = 'hello';\ntestLSBSteg.writeLSB({\n  imgBitmapData: imgBitmapData,\n  imgHeight: img.height,\n  imgWidth: img.width,\n  secretInfo,\n});\n```\n\n- Information Decoding\n\n```ts\nimport { LSBSteg } from './src';\n\nconst testLSBSteg = new LSBSteg();\nconst decodeSecret = testLSBSteg.readLSB({\n  imgBitmapData: imgBitmapData,\n  imgHeight: img.height,\n  imgWidth: img.width,\n});\n```\n\n**with QR Code ECC**\n\n- Information Encoding\n\n```ts\nimport { LSBSteg } from './src';\n\nconst testLSBSteg = new LSBSteg();\nconst secretInfo = 'hello';\ntestLSBSteg.writeLSB({\n  imgBitmapData: imgBitmapData,\n  imgHeight: img.height,\n  imgWidth: img.width,\n  secretInfo,\n  encMode: 'QRcode',\n  QRSize: 200,\n  mxMsgLen: 130\n});\n```\n\n- Information Decoding\n\n```ts\nimport { LSBSteg } from './src';\n\nconst testLSBSteg = new LSBSteg();\nconst decodeSecret = testLSBSteg.readLSB({\n  imgBitmapData: imgBitmapData,\n  imgHeight: img.height,\n  imgWidth: img.width,\n  decMode: 'QRcode'\n});\n```\n\n## :cookie: Demo\n```bash\n$ npm run start:demo\n```\n\n> Try the online [demo](https://antv.vision/vis-steg/) :point_left:\n> \n> - [Pipeline](https://gw.alipayobjects.com/zos/antfincdn/QqZ19SeFwS/pipeline.gif)\n> - [Vis-Image Transformation](https://gw.alipayobjects.com/zos/antfincdn/Wv%24IIck0F%24/vis-img-transfer.gif)\n\n## :link: Links\n- [API Reference](./docs/api/readme.md)\n## :seedling: Supported Algorithms\n\n- LSB: Least Significant Bit method for image steganography. The binary bits of the secret information was used to replace the bits of container image pixels. The replacing occurs from the least bit to the highest bit to retain the quality of container image.\n\n  > ### LSB Encode Process\n  >\n  > - ### Input\n  >\n  > ```\n  > - RGB (or gray) Image\n  > - Secret String\n  > - Encode Mode\n  > - Options\n  > ```\n  >\n  > - ### Process\n  >\n  > 1.  Adjust RGB (or gray) image to RGBA form.\n  > 2.  Add a head string for further check.\n  > 3.  Convert the head string, secret string length and secret string to bits array, and merge them together.\n  > 4.  Embed the bits array into the container image. The replacing is from the least bit to the highest bit.\n\n  > ### LSB Decode Process\n  >\n  > - ### Input\n  >\n  > ```\n  > - RGBA Image\n  > - Decode Mode\n  > ```\n  >\n  > - ### Process\n  >\n  > 1.  Read the head string for decoding check.\n  > 2.  Read the secret string length (64 bits).\n  > 3.  Read the secret string bits array and convert it to string.\n\n## License\n\nMIT\n","readmeFilename":"README.md"}