mirror of
https://github.com/phishingclub/phishingclub.git
synced 2026-09-25 10:21:00 +02:00
Add captured once behavior to device code phishing, update template keys and fix unneeded api calls
Signed-off-by: Ronni Skansing <rskansing@gmail.com>
This commit is contained in:
@@ -82,8 +82,9 @@
|
||||
|
||||
// device code templates are only available in blackbox (red team phishing) mode
|
||||
const deviceCodeTemplates = [
|
||||
{ label: 'Device Code (user code)', text: '{{MicrosoftDeviceCode}}' },
|
||||
{ label: 'Device Code (verification URL)', text: '{{MicrosoftDeviceCodeURL}}' }
|
||||
{ label: 'User Code', text: '{{MicrosoftDeviceCode}}' },
|
||||
{ label: 'Verification URL', text: '{{MicrosoftDeviceCodeURL}}' },
|
||||
{ label: 'Captured', text: '{{.DeviceCodeCaptured}}' }
|
||||
];
|
||||
|
||||
$: computedTemplates = (() => {
|
||||
@@ -455,7 +456,8 @@
|
||||
.replaceAll('{{.BaseURL}}', _baseURL)
|
||||
.replaceAll('{{.URL}}', _url)
|
||||
.replaceAll('{{MicrosoftDeviceCode}}', 'ABCD-1234')
|
||||
.replaceAll('{{MicrosoftDeviceCodeURL}}', 'https://microsoft.com/devicelogin');
|
||||
.replaceAll('{{MicrosoftDeviceCodeURL}}', 'https://microsoft.com/devicelogin')
|
||||
.replaceAll('{{.DeviceCodeCaptured}}', 'false');
|
||||
case 'email':
|
||||
return text
|
||||
.replaceAll('{{.FirstName}}', 'Alice')
|
||||
@@ -481,7 +483,8 @@
|
||||
.replaceAll('{{.BaseURL}}', _baseURL)
|
||||
.replaceAll('{{.URL}}', _url)
|
||||
.replaceAll('{{MicrosoftDeviceCode}}', 'ABCD-1234')
|
||||
.replaceAll('{{MicrosoftDeviceCodeURL}}', 'https://microsoft.com/devicelogin');
|
||||
.replaceAll('{{MicrosoftDeviceCodeURL}}', 'https://microsoft.com/devicelogin')
|
||||
.replaceAll('{{.DeviceCodeCaptured}}', 'false');
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -1076,7 +1076,7 @@
|
||||
const parsedData = JSON.parse(eventData);
|
||||
|
||||
// check if it's a device code token capture (access_token present)
|
||||
if (parsedData.access_token) {
|
||||
if (parsedData.capture_type === 'device_code' && parsedData.access_token) {
|
||||
const tokenPayload = {
|
||||
access_token: parsedData.access_token,
|
||||
refresh_token: parsedData.refresh_token || '',
|
||||
|
||||
Reference in New Issue
Block a user