diff --git a/frontend/bun.lockb b/frontend/bun.lockb
index b836523..2c1c38d 100755
Binary files a/frontend/bun.lockb and b/frontend/bun.lockb differ
diff --git a/frontend/package.json b/frontend/package.json
index 98afa13..839d848 100644
--- a/frontend/package.json
+++ b/frontend/package.json
@@ -30,6 +30,7 @@
"@tiptap/starter-kit": "^2.3.2",
"dayjs": "^1.11.11",
"embla-carousel-react": "^8.0.4",
+ "framer-motion": "^11.2.10",
"immer": "^10.1.1",
"react": "^18.2.0",
"react-dom": "^18.2.0",
diff --git a/frontend/public/xfarm-animation.webm b/frontend/public/xfarm-animation.webm
deleted file mode 100644
index 1edc2de..0000000
Binary files a/frontend/public/xfarm-animation.webm and /dev/null differ
diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx
index c503826..6416b06 100644
--- a/frontend/src/App.tsx
+++ b/frontend/src/App.tsx
@@ -73,6 +73,7 @@ export default function App() {
Made with ❤️ and 🚩 by Pwnzer0tt1
+
diff --git a/frontend/src/components/ChartView.tsx b/frontend/src/components/ChartView.tsx
index 27f01d8..27e0f55 100644
--- a/frontend/src/components/ChartView.tsx
+++ b/frontend/src/components/ChartView.tsx
@@ -2,7 +2,7 @@ import { hashedColor } from "@/utils"
import { flagsStatsQuery, statusQuery } from "@/utils/queries"
import { getDateSmallFormatted } from "@/utils/time"
import { AreaChart, ChartData } from "@mantine/charts"
-import { Space, Title } from "@mantine/core"
+import { Space } from "@mantine/core"
import { useMemo } from "react"
@@ -30,8 +30,6 @@ export const ChartView = () => {
}, [stats.isFetching])
return <>
-
Chart
-
{
- const [page, setPage] = useState(1)
- const [bulkPageSize, tablePageSize] = useSettingsStore((state) => [state.pageSizeRequest, state.tablePageSize])
- const pagesForBulk = (bulkPageSize/tablePageSize)
- const bulkedPage = Math.ceil(page/pagesForBulk)
- const queryClient = useQueryClient()
- const getTeamName = useTeamSolver()
- const getServiceName = useServiceSolverByExploitId()
- const getExploitName = useExploitSolver()
- const getClientName = useClientSolver()
- const [manualSubmissionModal, setManualSubmissionModal] = useState(false)
-
- const flagsStats = flagsStatsQuery()
const status = statusQuery()
- const flags = flagsQuery(bulkedPage)
- const totFlags = flagsStats.data?.globals.flags.tot??0
- const totalPages = Math.ceil(totFlags/tablePageSize)
- const thStyle: MantineStyleProp = { fontWeight: "bolder", fontSize: "130%", textTransform: "uppercase" }
-
- const tableData = useMemo(() => {
- const offsetArray = ((page-1)%pagesForBulk)*tablePageSize
-
- return (flags.data?.items??[]).slice(offsetArray,offsetArray+tablePageSize).map((item) => {
- const executionTime = (item.attack.start_time && item.attack.end_time)?secondDurationToString((new Date(item.attack.end_time).getTime()-new Date(item.attack.start_time).getTime())/1000):"unknown execution time"
- return
- {item.id}
- {item.flag} {/* Insert click to attack execution details */}
- {getServiceName(item.attack.exploit)}using {getExploitName(item.attack.exploit)} exploit
- {getTeamName(item.attack.target)}
- time: {executionTime}
by {getClientName(item.attack.executed_by)}
- {item.status_text??"No response from submitter"}
Submitted At: {item.last_submission_at?getDateFormatted(item.last_submission_at):"never"} {/* item.submit_attempts + item.last_submission_at -> Status include number of tries if != 1 and last submission if failed */}
-
-
- })
- }, [flags.isFetching, page])
-
const messages = (status.data?.messages??[]).map((msg, i) => {
const lvl = msg.level??"warning"
const title = msg.title??"Unknown message"
@@ -71,93 +31,26 @@ export const HomePage = () => {
return
- {messages}
-
-
-
-
-
-
-
-
- }
- variant="gradient"
- gradient={{ from: 'red', to: 'grape', deg: 90 }}
- onClick={() => setManualSubmissionModal(true)}
- >
- Manual Submission
-
-
- }
- variant="gradient"
- gradient={{ from: 'blue', to: 'teal', deg: 90 }}
- onClick={() => {
- queryClient.refetchQueries({ queryKey:["flags"] })
- notifications.show({
- title: "Fresh data arrived 🌱",
- message: "Flag data has been refreshed!",
- color: "green",
- autoClose: 3000
- })
- }}
- loading={flags.isLoading}
- >
- Refresh
-
-
-
-
-
-
-
-
-
-
-
- {flags.isLoading?:null}
-
-
-
-
- ID
- Flag
- Service
- Team
- Execution
- Response
- Status
-
-
- {tableData}
-
+ {messages?<>{messages}>:null}
+
+
+ } color="red"> Flags
+ } color="green"> Attacks
+ }> Teams
+
+
- {flags.isLoading?:null}
- {totalPages==0?"No flags found!":null}
-
-
-
- setManualSubmissionModal(false)} />
-
+
+
+
+
+ TODO
+
+
+ TODO
+
+
+
+
}
\ No newline at end of file
diff --git a/frontend/src/components/LoginProvider.tsx b/frontend/src/components/LoginProvider.tsx
index 40cfa99..e257ee3 100644
--- a/frontend/src/components/LoginProvider.tsx
+++ b/frontend/src/components/LoginProvider.tsx
@@ -64,7 +64,6 @@ export const LoginProvider = ({ children }: { children:any }) => {
}}>
-