
Research
PyPI Package Disguised as Instagram Growth Tool Harvests User Credentials
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
vue-auth-image
Advanced tools
A reusable directive for Vue.js that loads an image requiring authentication and includes it as data in-line in your web pages.
Contrary to other HTTP requests, browsers don't send common headers such as
Authorization
when retrieving an image specified in a <img>
tag.
This Vue.js directive overcomes this limitation by providing a way to load your
images as any other resources and then embedding them into your web pages using
the data:image/FILETYPE;base64
URI scheme.
$ npm install vue-auth-image --save
<script src="https://cdn.jsdelivr.net/npm/vue-auth-image/vue-auth-image.js"></script>
<!-- OR -->
<script src="https://cdn.jsdelivr.net/npm/vue-auth-image/vue-auth-image.min.js"></script>
To use vue-auth-image
with Nuxt.js, start by creating
a new plugin file name vue-auth-image.js
in your plugins/
directory. Add
the following content to it:
import Vue from 'vue';
import VueAuthImage from 'vue-auth-image';
Vue.use(VueAuthImage);
Then, add the plugin to your nuxt.config.js
at the root of your project:
plugins: [
'@/plugins/vue-auth-image.js'
]
A directive that requests an image URI asynchronously and embed it into your
<img>
tag using the data URI scheme.
import axios from 'axios';
import Vue from 'vue';
import VueAuthImage from 'vue-auth-image';
// register vue-auth-image directive
Vue.use(VueAuthImage);
// set Authorization header used by axios
var authHeader = 'Bearer ' + localStorage.getItem('id_token');
axios.defaults.headers.common['Authorization'] = authHeader;
Once the directive is registered, you can use it in your Vue templates.
<template>
<div>
<img v-auth-image="https://api.app.com/images/authenticatedImg.png">
</div>
</template>
See /example
for a demo. To build it, run npm install && npm run build
.
0.0.3 - 2019-11-10
FAQs
Vue directive to load and display secured images
The npm package vue-auth-image receives a total of 263 weekly downloads. As such, vue-auth-image popularity was classified as not popular.
We found that vue-auth-image demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
Product
Socket now supports pylock.toml, enabling secure, reproducible Python builds with advanced scanning and full alignment with PEP 751's new standard.
Security News
Research
Socket uncovered two npm packages that register hidden HTTP endpoints to delete all files on command.