
Research
/Security News
Malicious npm Packages Target WhatsApp Developers with Remote Kill Switch
Two npm packages masquerading as WhatsApp developer libraries include a kill switch that deletes all files if the phone number isn’t whitelisted.
exiflocation
Advanced tools
Extract lat long data and get map location URLs from EXIF data in images.
Client and server-side GPS coordinate extraction using JavaScript.
You'll need Component and GNU make. Then run:
git clone https://github.com/mattcg/exiflocation.git
cd exiflocation/
make
Alternatively, use Component to install to your project.
component install exiflocation
ExifLocation is also available using Bower.
bower install exiflocation
See example/
for a complete example.
ExifLocation uses FileReader and DataView (available since Chrome 9, Firefox 15, IE 10, Safari 5.1). Use this method to check support in the current runtime.
Broader support is possible using jDataView.
Pass a FileList as the first argument. The progressCb
argument is a function that's executed once for each file in the list, receiving an error (if any) as the first argument and the ExifLocation instance as the second. The cb
argument is executed once all the files have been loaded and receives an array of ExifLocation instances in the same order as the corresponding files in fileList
.
var file = document.getElementById('file');
file.multiple = true;
file.addEventListener('change', function(event) {
ExifLocation.loadFromFileList(event.target.files, function(err, exifLocation) {
if (!err) {
console.log(exifLocation.getGoogleMapsUrl(location.protocol));
}
});
}, false);
Receives a File as the first argument. The callback function receives an error object or null as the first argument and the ExifLocation instance as the second.
As above, but with an ArrayBuffer.
Returns the decimal latitude.
Returns the decimal longitude.
Get a Google Maps URL for the embedded location. The protocol is relative by default. The type
parameter is either 'm'
for the normal map (default), 'k'
for satellite, 'h'
for hybrid, 'p'
for terrain or 'e'
for Google Earth.
ExifLocation is copyright © 2013 Matthew Caruana Galizia, licensed under an MIT license.
FAQs
Extract lat long data and get map location URLs from EXIF data in images.
The npm package exiflocation receives a total of 1 weekly downloads. As such, exiflocation popularity was classified as not popular.
We found that exiflocation 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
/Security News
Two npm packages masquerading as WhatsApp developer libraries include a kill switch that deletes all files if the phone number isn’t whitelisted.
Research
/Security News
Socket uncovered 11 malicious Go packages using obfuscated loaders to fetch and execute second-stage payloads via C2 domains.
Security News
TC39 advances 11 JavaScript proposals, with two moving to Stage 4, bringing better math, binary APIs, and more features one step closer to the ECMAScript spec.