Skip to content

Sigma rules fun API. A restful API which contains most funny sigma rules. Sigma-rule-api made by subhranhsu sekhar choudhury.

License

Notifications You must be signed in to change notification settings

subhranshuchoudhury/sigma-rules-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

7745506 · Jun 19, 2022

History

12 Commits
Jun 18, 2022
Jun 18, 2022
Jun 17, 2022
Jun 17, 2022
Jun 18, 2022
Jun 19, 2022
Jun 18, 2022
Jun 18, 2022
Jun 18, 2022

Repository files navigation

Men Sigma Rule API

  • This API provides funny sigma rules from memes.
  • Use it for fun, remeber all the rules are from internet.
  • Kindly don't take the rules seriously.
  • NOTE: Use "http" protocol for no error. eg. http://sigmarule.herokuapp.com/sigmarule


Fetch all the Sigma Rules:

//#### NOTE: Use "http" protocol for no error. eg. http://sigmarule.herokuapp.com/sigmarule
const URL = "http://sigmarule.herokuapp.com/sigmarule"
const getPosts = async () => {

    const response = await fetch(URL);
    if (!response.ok) {
        throw new Error("Error in fetching JSON data, Contact subhranshuchoudhury");
    }
    const data = await response.json();
    return data;

}

getPosts()
    .then(mydata => {
        getRule(mydata);
    })
    .catch(error => {
        alert(error);

    });

function getRule(Rules) {
    console.log(Rules); //Rules[index].rule
} 

Fetch random Sigma Rule:

//#### NOTE: Use "http" protocol for no error. eg. http://sigmarule.herokuapp.com/sigmarule
const URL = "http://sigmarule.herokuapp.com/sigmarule/random"
const getPosts = async () => {

    const response = await fetch(URL);
    if (!response.ok) {
        throw new Error("Error in fetching JSON data, Contact subhranshuchoudhury");
    }
    const data = await response.json();
    return data;

}

getPosts()
    .then(mydata => {
        getRule(mydata);
    })
    .catch(error => {
        alert(error);

    });

function getRule(Rules) {
    console.log(Rules.rule)
}

Endpoints:

NOTE: Use "http" protocol for no error. eg. http://sigmarule.herokuapp.com/sigmarule


Author: Subhranshu Choudhury