Skip to content

Commit

Permalink
Merge branch 'master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
gitworkflows authored Sep 17, 2024
2 parents 6c820e5 + e9251c4 commit 26cd8a9
Show file tree
Hide file tree
Showing 95 changed files with 8,484 additions and 2,194 deletions.
4 changes: 2 additions & 2 deletions .github/SECURITY.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ Thank you for helping to keep reNgine and its users safe!
**What do I get in return?**

* Much thanks from Maintainer and the community
* Monetary Rewards
* CVE ID(s)

## Past Security Vulnerabilities
Expand All @@ -41,6 +40,7 @@ Thanks to these individuals for reporting Security Issues in reNgine.
### 2024

* [HIGH] [Command Injection](https://github.com/yogeshojha/rengine/security/advisories/GHSA-fx7f-f735-vgh4) in Waf Detector, Reported by [n-thumann](https://github.com/n-thumann)
* [MEDIUM] [Stored XSS](https://github.com/yogeshojha/rengine/security/advisories/GHSA-96q4-fj2m-jqf7) in in Vulnerability Page, Reported by [Touhid M Shaikh](https://github.com/touhidshaikh)

### 2022

Expand Down Expand Up @@ -72,6 +72,6 @@ Thanks to these individuals for reporting Security Issues in reNgine.

* [LOW] [Stored XSS](https://huntr.dev/bounties/693a7d23-c5d4-448e-bbf6-50b3f0ad8544/) on Target Summary via Todo, Reported by [TheLabda](https://github.com/thelabda)

* [LOW] [Stored XSS](https://huntr.dev/bounties/81c48a07-9cb8-4da8-babc-28a4076a5e92/) on Nuclei Template Summary via maliclous Nuclei Template, Reported by [Walleson Moura](https://github.com/phor3nsic)
* [LOW] [Stored XSS](https://huntr.dev/bounties/81c48a07-9cb8-4da8-babc-28a4076a5e92/) on Nuclei Template Summary via malicious Nuclei Template, Reported by [Walleson Moura](https://github.com/phor3nsic)

* [MEDIUM] [Path Traversal/LFI](https://huntr.dev/bounties/5df1a485-7a1e-411d-9664-0f4343e8512a/), reported by [Koen Molenaar](https://github.com/k0enm)
111 changes: 86 additions & 25 deletions .github/workflows/auto-comment.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,98 @@
name: 👋 Auto Comment
on: [issues, pull_request]
name: 💬 Auto Comment

on:
issues:
types: [opened]
pull_request:
types: [opened, closed]
pull_request_target:
types: [opened, closed]

permissions:
issues: write
pull-requests: write

jobs:
run:
auto_comment:
runs-on: ubuntu-latest
steps:
- uses: bubkoo/auto-comment@v1.1.2
- name: 🤖 Auto Comment on Issues and PRs
uses: actions/github-script@v7
with:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
issuesOpened: >
👋 Hi @{{ author }},
Issues is only for reporting a bug/feature request. Please read documentation before raising an issue https://rengine.wiki
For very limited support, questions, and discussions, please join reNgine Discord channel: https://discord.gg/azv6fzhNCE
Please include all the requested and relevant information when opening a bug report. Improper reports will be closed without any response.
pullRequestOpened: >
👋 Hi @{{ author }},
github-token: ${{secrets.GITHUB_TOKEN}}
script: |
const { owner, repo } = context.repo;
const author = context.payload.sender.login;
if (context.eventName === 'issues' && context.payload.action === 'opened') {
const issueTitle = context.payload.issue.title.toLowerCase();
let commentBody;
if (issueTitle.includes('feat')) {
commentBody = `Hey @${author}! 🚀 Thanks for this exciting feature idea!
Thank you for sending this pull request.
We love seeing fresh concepts that could take reNgine to the next level. 🌟
To help us understand your vision better, could you:
📝 Provide a detailed description of the feature
🎯 Explain the problem it solves or the value it adds
💡 Share any implementation ideas you might have
Your input is invaluable in shaping the future of reNgine. Let's innovate together! 💪`;
} else {
commentBody = `Hey @${author}! 👋 Thanks for flagging this bug! 🐛🔍
Please make sure you have followed our [contribution guidelines](https://github.com/yogeshojha/rengine/blob/master/.github/CONTRIBUTING.md).
You're our superhero bug hunter! 🦸‍♂️🦸‍♀️ Before we suit up to squash this bug, could you please:
📚 Double-check our documentation: https://rengine.wiki
🕵️ Make sure it's not a known issue
📝 Provide all the juicy details about this sneaky bug
Once again - thanks for your vigilance! 🛠️🚀`;
}
github.rest.issues.createComment({
issue_number: context.issue.number,
owner,
repo,
body: commentBody
});
} else if ((context.eventName === 'pull_request' || context.eventName === 'pull_request_target') && context.payload.action === 'opened') {
github.rest.issues.createComment({
issue_number: context.issue.number,
owner,
repo,
body: `Woohoo @${author}! 🎉 You've just dropped some hot new code! 🔥
We will review this PR as soon as possible. Thank you for your patience.
Hang tight while we review this! You rock! 🤘`
});
} else if ((context.eventName === 'pull_request' || context.eventName === 'pull_request_target') && context.payload.action === 'closed') {
const isPRMerged = context.payload.pull_request.merged;
let commentBody;
pullRequestClosed: >
🚀 Hi @{{ author }},
if (isPRMerged) {
commentBody = `Holy smokes! 🤯 You've just made reNgine even more awesome!
You are amazing! Thank you for your contributions. Your contributions are what makes reNgine awesome!
Your code is now part of the reNgine hall of fame. 🏆
Keep the cool ideas coming - maybe next time you'll break the internet! 💻💥
This pull request has now been closed.
Virtual high fives all around! 🙌`;
} else {
commentBody = `Hey, thanks for your contribution! 🙏
We look forward to your more contributions and support.
We appreciate the time and effort you put into this PR. Sadly this is not the right fit for reNgine at the moment.
While we couldn't merge it this time, we value your interest in improving reNgine.
Feel free to reach out if you have any questions. Thanks again!`;
}
Thanks
github.rest.issues.createComment({
issue_number: context.issue.number,
owner,
repo,
body: commentBody
});
}
60 changes: 60 additions & 0 deletions .github/workflows/auto-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: Update Version and Changelog and Readme

on:
release:
types: [published]

jobs:
update-version-and-changelog:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0

- name: Get latest release info
id: get_release
uses: actions/github-script@v6
with:
script: |
const release = await github.rest.repos.getLatestRelease({
owner: context.repo.owner,
repo: context.repo.repo,
});
core.setOutput('tag_name', release.data.tag_name);
core.setOutput('body', release.data.body);
- name: Update version file
run: echo ${{ steps.get_release.outputs.tag_name }} > web/.version

- name: Update CHANGELOG.md
run: |
echo "# Changelog" > CHANGELOG.md.new
echo "" >> CHANGELOG.md.new
echo "## ${{ steps.get_release.outputs.tag_name }}" >> CHANGELOG.md.new
echo "" >> CHANGELOG.md.new
echo "${{ steps.get_release.outputs.body }}" >> CHANGELOG.md.new
echo "" >> CHANGELOG.md.new
if [ -f CHANGELOG.md ]; then
sed '1,2d' CHANGELOG.md >> CHANGELOG.md.new
fi
mv CHANGELOG.md.new CHANGELOG.md
- name: Update README.md
run: |
sed -i 's|https://img.shields.io/badge/version-.*-informational|https://img.shields.io/badge/version-${{ steps.get_release.outputs.tag_name }}-informational|g' README.md
- name: Commit and push changes
run: |
git config --local user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config --local user.name "github-actions[bot]"
git add web/.version CHANGELOG.md README.md
if git diff --staged --quiet; then
echo "No changes to commit"
else
git commit -m "reNgine release: ${{ steps.get_release.outputs.tag_name }} :rocket:"
git push origin HEAD:${{ github.event.repository.default_branch }}
fi
33 changes: 21 additions & 12 deletions .github/workflows/build-pr.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: 🌄 Build Docker image for pull request
name: 🏗️ Build Docker image for pull request

on:
pull_request:
Expand All @@ -8,33 +8,42 @@ on:

jobs:
build:
name: Build Docker image
name: 🐳 Build Docker image
runs-on: ubuntu-latest
strategy:
matrix:
platform:
- linux/amd64
- linux/arm64
# - linux/arm/v7
steps:
- name: Checkout the git repo
- name: 📥 Checkout the git repo
uses: actions/checkout@v4

- name: Log in to Docker Hub
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: 🖥️ Set up QEMU
uses: docker/setup-qemu-action@v3

- name: 🏗️ Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Extract metadata (tags, labels) for Docker
- name: 🏷️ Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
uses: docker/metadata-action@v5
with:
images: yogeshojha/rengine
tags: |
type=raw,value=pr-${{ github.event.pull_request.number }}
type=sha,prefix=sha-
type=ref,event=branch
type=ref,event=pr
- name: Build Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
- name: 🏗️ Build Docker image
uses: docker/build-push-action@v5
with:
context: web/
platforms: ${{ matrix.platform }}
push: false
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
42 changes: 30 additions & 12 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,40 +1,58 @@
name: Build Docker image
name: 🚀 Build and Push Docker image

on:
push:
branches: [ master ]
release:
types: [published]
schedule:
- cron: '0 18 * * 5'
- cron: '0 0 */5 * *' # Run every 5 days at midnight UTC

jobs:
build:
name: Build Docker image
build-and-push:
name: 🐳 Build and Push Docker image
runs-on: ubuntu-latest
strategy:
matrix:
platform:
- linux/amd64
- linux/arm64
steps:
- name: Checkout the git repo
- name: 📥 Checkout the git repo
uses: actions/checkout@v4

- name: Log in to Docker Hub
uses: docker/login-action@f054a8b539a109f9f41c372932f1ae047eff08c9
- name: 🖥️ Set up QEMU
uses: docker/setup-qemu-action@v3

- name: 🛠️ Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: 🔑 Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Extract metadata (tags, labels) for Docker
- name: 🏷️ Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@98669ae865ea3cffbcbaa878cf57c20bbf1c6c38
uses: docker/metadata-action@v5
with:
images: yogeshojha/rengine
tags: |
type=raw,value=${{ matrix.platform }}-latest,enable={{is_default_branch}}
type=semver,pattern=${{ matrix.platform }}-{{version}}
type=semver,pattern=${{ matrix.platform }}-{{major}}.{{minor}}
type=semver,pattern=${{ matrix.platform }}-{{major}}
type=sha,prefix=${{ matrix.platform }}-sha-
type=schedule,pattern=${{ matrix.platform }}-{{date 'YYYYMMDD'}}
- name: Build Docker image
uses: docker/build-push-action@ad44023a93711e3deb337508980b4b5e9bcdc5dc
- name: 🏗️ Build and push Docker image
uses: docker/build-push-action@v5
with:
context: web/
push: true
platforms: ${{ matrix.platform }}
push: ${{ github.event_name != 'pull_request' }}
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
Loading

0 comments on commit 26cd8a9

Please sign in to comment.