mirror of
https://github.com/sharevb/it-tools.git
synced 2026-11-22 14:01:42 +03:00
Merge branch 'feat/malicious-link-checker' into chore/all-my-stuffs
# Conflicts: # src/tools/index.ts
This commit is contained in:
commit
0da083901f
4 files changed
+79
-1
No files matched your search
Generated
+1
-1
@@ -4976,7 +4976,7 @@ packages:
|
|||||||
/@vueuse/shared@10.0.0(vue@3.3.4):
|
/@vueuse/shared@10.0.0(vue@3.3.4):
|
||||||
resolution: {integrity: sha512-Zh3LgJqvUBWVY3SiMvXanTcfAneGbt63QPczBRDNgQ6jd/ehodO9a1lCFzaA6SWJJoI+ugVTjHFYJdoR656DVQ==}
|
resolution: {integrity: sha512-Zh3LgJqvUBWVY3SiMvXanTcfAneGbt63QPczBRDNgQ6jd/ehodO9a1lCFzaA6SWJJoI+ugVTjHFYJdoR656DVQ==}
|
||||||
dependencies:
|
dependencies:
|
||||||
vue-demi: 0.14.5(vue@3.3.4)
|
vue-demi: 0.14.10(vue@3.3.4)
|
||||||
transitivePeerDependencies:
|
transitivePeerDependencies:
|
||||||
- '@vue/composition-api'
|
- '@vue/composition-api'
|
||||||
- vue
|
- vue
|
||||||
|
|||||||
@@ -25,6 +25,7 @@ import { tool as phpArrayToJson } from './php-array-to-json';
|
|||||||
import { tool as jsonSizeAnalyzer } from './json-size-analyzer';
|
import { tool as jsonSizeAnalyzer } from './json-size-analyzer';
|
||||||
import { tool as jsonToCsharp } from './json-to-csharp';
|
import { tool as jsonToCsharp } from './json-to-csharp';
|
||||||
import { tool as luhnValidator } from './luhn-validator';
|
import { tool as luhnValidator } from './luhn-validator';
|
||||||
|
import { tool as maliciousLinksTester } from './malicious-links-tester';
|
||||||
|
|
||||||
import { tool as cssXpathConverter } from './css-xpath-converter';
|
import { tool as cssXpathConverter } from './css-xpath-converter';
|
||||||
import { tool as cssSelectorsMemo } from './css-selectors-memo';
|
import { tool as cssSelectorsMemo } from './css-selectors-memo';
|
||||||
@@ -220,6 +221,7 @@ export const toolsByCategory: ToolCategory[] = [
|
|||||||
jsUnobfuscator,
|
jsUnobfuscator,
|
||||||
jsonToPhpArray,
|
jsonToPhpArray,
|
||||||
phpArrayToJson,
|
phpArrayToJson,
|
||||||
|
maliciousLinksTester,
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -0,0 +1,12 @@
|
|||||||
|
import { ShieldCheck } from '@vicons/tabler';
|
||||||
|
import { defineTool } from '../tool';
|
||||||
|
|
||||||
|
export const tool = defineTool({
|
||||||
|
name: 'Malicious Links Checker',
|
||||||
|
path: '/malicious-links-checker',
|
||||||
|
description: 'Check an url against Google Safe Browsing service',
|
||||||
|
keywords: ['malicious', 'links', 'checker', 'check', 'safe', 'safe-browsing', 'google'],
|
||||||
|
component: () => import('./malicious-links-checker.vue'),
|
||||||
|
icon: ShieldCheck,
|
||||||
|
createdAt: new Date('2024-05-11'),
|
||||||
|
});
|
||||||
@@ -0,0 +1,64 @@
|
|||||||
|
<script setup lang="ts">
|
||||||
|
import { request } from 'malicious-link-detector';
|
||||||
|
import { useValidation } from '@/composable/validation';
|
||||||
|
import { useQueryParam } from '@/composable/queryParams';
|
||||||
|
|
||||||
|
/*
|
||||||
|
What tool do you want?
|
||||||
|
Send Message via Whatsapp Web
|
||||||
|
|
||||||
|
Describe the solution you'd like
|
||||||
|
I would like to have an input field where I can write a mobile number and a textfield, where I can send a message.
|
||||||
|
A button "Send" which will open the follwowing url:
|
||||||
|
|
||||||
|
https://web.whatsapp.com/send/?phone=THE_MOBILE_NUMBER&text=THE_MESSAGE
|
||||||
|
|
||||||
|
it is important that the number is formatted correctly:
|
||||||
|
the "0" at the beginning should be "49" (for germany) and all spaces or characters like "-" should be removed.
|
||||||
|
*/
|
||||||
|
|
||||||
|
const url = useQueryParam({ name: 'url', defaultValue: '' });
|
||||||
|
const urlValidation = useValidation({
|
||||||
|
source: url,
|
||||||
|
rules: [
|
||||||
|
{
|
||||||
|
message: 'Invalid url string',
|
||||||
|
validator: (value) => {
|
||||||
|
try {
|
||||||
|
const _ = (new URL(value));
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
catch {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
],
|
||||||
|
});
|
||||||
|
const result = computedAsync(async () => {
|
||||||
|
const urlValue = url.value;
|
||||||
|
return await request(urlValue);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<c-input-text
|
||||||
|
v-model:value="url"
|
||||||
|
label="Website url"
|
||||||
|
placeholder="Put your website url here..."
|
||||||
|
clearable
|
||||||
|
mb-2
|
||||||
|
:validation="urlValidation"
|
||||||
|
/>
|
||||||
|
|
||||||
|
<c-alert v-if="result !== 'Safe'" type="error">
|
||||||
|
Danger! '{{ url }}' website is listed as not safe by Google Safe Browsing: <strong>{{ result }}</strong>
|
||||||
|
<c-alert />
|
||||||
|
</c-alert>
|
||||||
|
<c-alert v-if="result" type="success">
|
||||||
|
This website is safe.
|
||||||
|
<c-alert />
|
||||||
|
</c-alert>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
Reference in new issue
Block a user