Skip to content

Commit 3acfdb1

Browse files
Merge pull request #2592 from KelvinTegelaar/dev
Dev to release
2 parents 4269a2c + bb12565 commit 3acfdb1

29 files changed

+802
-128
lines changed

package-lock.json

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "cipp",
3-
"version": "5.8.5",
3+
"version": "5.9.0",
44
"description": "The CyberDrain Improved Partner Portal is a portal to help manage administration for Microsoft Partners.",
55
"homepage": "https://cipp.app/",
66
"bugs": {

public/version_latest.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
5.8.5
1+
5.9.0

src/_nav.jsx

+10
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,11 @@ const _nav = [
4545
name: 'Users',
4646
to: '/identity/administration/users',
4747
},
48+
{
49+
component: CNavItem,
50+
name: 'Risky Users',
51+
to: '/identity/administration/risky-users',
52+
},
4853
{
4954
component: CNavItem,
5055
name: 'Groups',
@@ -114,6 +119,11 @@ const _nav = [
114119
name: 'AAD Connect Report',
115120
to: '/identity/reports/azure-ad-connect-report',
116121
},
122+
{
123+
component: CNavItem,
124+
name: 'Risk Detections',
125+
to: '/identity/reports/risk-detections',
126+
},
117127
],
118128
},
119129
{

src/components/forms/RFFComponents.jsx

+12-6
Original file line numberDiff line numberDiff line change
@@ -470,19 +470,25 @@ RFFCFormSelect.propTypes = {
470470
export function Condition({ when, is, children, like, regex }) {
471471
return (
472472
<>
473-
{is && (
473+
{is !== undefined && (
474474
<Field name={when} subscription={{ value: true }}>
475-
{({ input: { value } }) => (value === is ? children : null)}
475+
{({ input: { value } }) => {
476+
return value === is ? children : null
477+
}}
476478
</Field>
477479
)}
478-
{like && (
480+
{like !== undefined && (
479481
<Field name={when} subscription={{ value: true }}>
480-
{({ input: { value } }) => (value.includes(like) ? children : null)}
482+
{({ input: { value } }) => {
483+
return value.includes(like) ? children : null
484+
}}
481485
</Field>
482486
)}
483-
{regex && (
487+
{regex !== undefined && (
484488
<Field name={when} subscription={{ value: true }}>
485-
{({ input: { value } }) => (value.match(regex) ? children : null)}
489+
{({ input: { value } }) => {
490+
return value.match(regex) ? children : null
491+
}}
486492
</Field>
487493
)}
488494
</>

src/components/layout/AppHeader.jsx

+25-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,12 @@ import { AppHeaderSearch } from 'src/components/header'
1515
import { CippActionsOffcanvas, TenantSelector } from '../utilities'
1616
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
1717
import { faBars } from '@fortawesome/free-solid-svg-icons'
18-
import { setCurrentTheme, setUserSettings, toggleSidebarShow } from 'src/store/features/app'
18+
import {
19+
setCurrentTheme,
20+
setSetupCompleted,
21+
setUserSettings,
22+
toggleSidebarShow,
23+
} from 'src/store/features/app'
1924
import { useMediaPredicate } from 'react-media-hook'
2025
import {
2126
useGenericGetRequestQuery,
@@ -92,6 +97,25 @@ const AppHeader = () => {
9297
}
9398
}, [delay, state])
9499
}
100+
//useEffect to check if any of the dashboard alerts contained the key "setupCompleted" and if so,
101+
//check if the value of this key is false. If so, set the setupCompleted state to false
102+
//if none is found, set the setupCompleted state to true
103+
useEffect(() => {
104+
if (dashboard && Array.isArray(dashboard) && dashboard.length >= 1) {
105+
console.log('Finding if setup is completed.')
106+
const setupCompleted = dashboard.find((alert) => alert && alert.setupCompleted === false)
107+
if (setupCompleted) {
108+
console.log("Setup isn't completed yet, we found a match with false.")
109+
dispatch(setSetupCompleted({ setupCompleted: false }))
110+
} else {
111+
console.log('Setup is completed.')
112+
dispatch(setSetupCompleted({ setupCompleted: true }))
113+
}
114+
} else {
115+
console.log('Setup is completed.')
116+
dispatch(setSetupCompleted({ setupCompleted: true }))
117+
}
118+
}, [dashboard, dispatch])
95119

96120
useEffect(() => {
97121
if (cippQueueList.isUninitialized && (cippQueueList.isFetching || cippQueueList.isLoading)) {

src/components/tables/CippTable.jsx

+7-1
Original file line numberDiff line numberDiff line change
@@ -644,7 +644,13 @@ export default function CippTable({
644644
if (typeof value === 'object' && !Array.isArray(value)) {
645645
Object.assign(output, flatten(value, newKey))
646646
} else {
647-
output[newKey] = value
647+
if (Array.isArray(value)) {
648+
value.map((item, idx) => {
649+
Object.assign(output, flatten(item, `${newKey}[${idx}]`))
650+
})
651+
} else {
652+
output[newKey] = value
653+
}
648654
}
649655
return output
650656
}, {})

src/components/utilities/CippActionsOffcanvas.jsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -345,7 +345,7 @@ export default function CippActionsOffcanvas(props) {
345345
}
346346
let actionsSelectorsContent
347347
try {
348-
actionsSelectorsContent = props.actionsSelect.map((action, index) => (
348+
actionsSelectorsContent = props?.actionsSelect?.map((action, index) => (
349349
<CListGroupItem className="" component="label" color={action.color} key={index}>
350350
{action.label}
351351
<CListGroupItem

src/data/standards.json

+126-14
Original file line numberDiff line numberDiff line change
@@ -855,22 +855,38 @@
855855
"label": "Publishing Editor - The user can create, read, edit, and delete all items in the folder, and create subfolders.",
856856
"value": "PublishingEditor"
857857
},
858+
{
859+
"label": "Editor - The user can create items in the folder. The contents of the folder do not appear.",
860+
"value": "Editor"
861+
},
862+
{
863+
"label": "Publishing Author. The user can read, create all items/subfolders. Can modify and delete only items they create.",
864+
"value": "PublishingAuthor"
865+
},
866+
{
867+
"label": "Author - The user can create and read items, and modify and delete items that they create.",
868+
"value": "Author"
869+
},
870+
{
871+
"label": "Non Editing Author - The user has full read access and create items. Can can delete only own items.",
872+
"value": "NonEditingAuthor"
873+
},
858874
{
859875
"label": "Reviewer - The user can read all items in the folder.",
860876
"value": "Reviewer"
861877
},
862878
{
863-
"label": "Editor - The user can create items in the folder. The contents of the folder do not appear.",
879+
"label": "Contributor - The user can create items and folders.",
864880
"value": "Contributor"
865881
},
866-
{
867-
"label": "Limited Details - The user can view free/busy time within the calendar and the subject and location of appointments.",
868-
"value": "LimitedDetails"
869-
},
870882
{
871883
"label": "Availability Only - Indicates that the user can view only free/busy time within the calendar.",
872884
"value": "AvailabilityOnly"
873885
},
886+
{
887+
"label": "Limited Details - The user can view free/busy time within the calendar and the subject and location of appointments.",
888+
"value": "LimitedDetails"
889+
},
874890
{
875891
"label": "None - The user has no permissions on the folder.",
876892
"value": "none"
@@ -1366,6 +1382,67 @@
13661382
"impact": "Low Impact",
13671383
"impactColour": "info"
13681384
},
1385+
{
1386+
"name": "standards.intuneBrandingProfile",
1387+
"cat": "Intune Standards",
1388+
"tag": ["lowimpact"],
1389+
"helpText": "Sets the branding profile for the Intune Company Portal app. This is a tenant wide setting and overrules any settings set on the app level.",
1390+
"addedComponent": [
1391+
{
1392+
"type": "input",
1393+
"name": "standards.intuneBrandingProfile.displayName",
1394+
"label": "Organization name"
1395+
},
1396+
{
1397+
"type": "boolean",
1398+
"name": "standards.intuneBrandingProfile.showLogo",
1399+
"label": "Show logo"
1400+
},
1401+
{
1402+
"type": "boolean",
1403+
"name": "standards.intuneBrandingProfile.showDisplayNameNextToLogo",
1404+
"label": "Show organization name next to logo"
1405+
},
1406+
{
1407+
"type": "input",
1408+
"name": "standards.intuneBrandingProfile.contactITName",
1409+
"label": "Contact IT name"
1410+
},
1411+
{
1412+
"type": "input",
1413+
"name": "standards.intuneBrandingProfile.contactITPhoneNumber",
1414+
"label": "Contact IT phone number"
1415+
},
1416+
{
1417+
"type": "input",
1418+
"name": "standards.intuneBrandingProfile.contactITEmailAddress",
1419+
"label": "Contact IT email address"
1420+
},
1421+
{
1422+
"type": "input",
1423+
"name": "standards.intuneBrandingProfile.contactITNotes",
1424+
"label": "Contact IT notes"
1425+
},
1426+
{
1427+
"type": "input",
1428+
"name": "standards.intuneBrandingProfile.onlineSupportSiteName",
1429+
"label": "Online support site name"
1430+
},
1431+
{
1432+
"type": "input",
1433+
"name": "standards.intuneBrandingProfile.onlineSupportSiteUrl",
1434+
"label": "Online support site URL"
1435+
},
1436+
{
1437+
"type": "input",
1438+
"name": "standards.intuneBrandingProfile.privacyUrl",
1439+
"label": "Privacy statement URL"
1440+
}
1441+
],
1442+
"label": "Set Intune Company Portal branding profile",
1443+
"impact": "Low Impact",
1444+
"impactColour": "info"
1445+
},
13691446
{
13701447
"name": "standards.intuneDeviceReg",
13711448
"cat": "Intune Standards",
@@ -1401,6 +1478,22 @@
14011478
"impact": "Low Impact",
14021479
"impactColour": "info"
14031480
},
1481+
{
1482+
"name": "standards.TenantDefaultTimezone",
1483+
"cat": "SharePoint Standards",
1484+
"tag": ["lowimpact"],
1485+
"helpText": "Sets the default timezone for the tenant. This will be used for all new users and sites.",
1486+
"addedComponent": [
1487+
{
1488+
"type": "TimezoneSelect",
1489+
"name": "standards.TenantDefaultTimezone.Timezone",
1490+
"label": "Timezone"
1491+
}
1492+
],
1493+
"label": "Set Default Timezone for Tenant",
1494+
"impact": "Low Impact",
1495+
"impactColour": "info"
1496+
},
14041497
{
14051498
"name": "standards.DisableAddShortcutsToOneDrive",
14061499
"cat": "SharePoint Standards",
@@ -1517,19 +1610,38 @@
15171610
"impactColour": "danger"
15181611
},
15191612
{
1520-
"name": "standards.TenantDefaultTimezone",
1613+
"name": "standards.sharingDomainRestriction",
15211614
"cat": "SharePoint Standards",
1522-
"tag": ["lowimpact"],
1523-
"helpText": "Sets the default timezone for the tenant. This will be used for all new users and sites.",
1615+
"tag": ["highimpact", "CIS"],
1616+
"helpText": "Restricts sharing to only users with the specified domain. This is useful for organizations that only want to share with their own domain.",
15241617
"addedComponent": [
15251618
{
1526-
"type": "TimezoneSelect",
1527-
"name": "standards.TenantDefaultTimezone.Timezone",
1528-
"label": "Timezone"
1619+
"type": "Select",
1620+
"name": "standards.sharingDomainRestriction.Mode",
1621+
"label": "Limit external sharing by domains",
1622+
"values": [
1623+
{
1624+
"label": "Off",
1625+
"value": "none"
1626+
},
1627+
{
1628+
"label": "Restirct sharing to specific domains",
1629+
"value": "allowList"
1630+
},
1631+
{
1632+
"label": "Block sharing to specific domains",
1633+
"value": "blockList"
1634+
}
1635+
]
1636+
},
1637+
{
1638+
"type": "input",
1639+
"name": "standards.sharingDomainRestriction.Domains",
1640+
"label": "Domains to allow/block, comma separated"
15291641
}
15301642
],
1531-
"label": "Set Default Timezone for Tenant",
1532-
"impact": "Low Impact",
1533-
"impactColour": "info"
1643+
"label": "Restrict sharing to a specific domain",
1644+
"impact": "High Impact",
1645+
"impactColour": "danger"
15341646
}
15351647
]

src/importsMap.jsx

+2
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ import React from 'react'
1515
"/identity/administration/jit-admin": React.lazy(() => import('./views/identity/administration/DeployJITAdmin')),
1616
"/identity/administration/ViewBec": React.lazy(() => import('./views/identity/administration/ViewBEC')),
1717
"/identity/administration/users": React.lazy(() => import('./views/identity/administration/Users')),
18+
"/identity/administration/risky-users": React.lazy(() => import('./views/identity/administration/RiskyUsers')),
1819
"/identity/administration/devices": React.lazy(() => import('./views/identity/administration/Devices')),
1920
"/identity/administration/groups/add": React.lazy(() => import('./views/identity/administration/AddGroup')),
2021
"/identity/administration/group-templates": React.lazy(() => import('./views/identity/administration/GroupTemplates')),
@@ -32,6 +33,7 @@ import React from 'react'
3233
"/identity/reports/inactive-users-report": React.lazy(() => import('./views/identity/reports/InactiveUsers')),
3334
"/identity/reports/Signin-report": React.lazy(() => import('./views/identity/reports/SignIns')),
3435
"/identity/reports/azure-ad-connect-report": React.lazy(() => import('./views/identity/reports/AzureADConnectReport')),
36+
"/identity/reports/risk-detections": React.lazy(() => import('./views/identity/reports/RiskDetections')),
3537
"/tenant/administration/tenants": React.lazy(() => import('./views/tenant/administration/Tenants')),
3638
"/tenant/administration/tenants/edit": React.lazy(() => import('./views/tenant/administration/EditTenant')),
3739
"/tenant/administration/partner-relationships": React.lazy(() => import('./views/tenant/administration/PartnerRelationships')),

src/routes.json

+12
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,12 @@
9999
"component": "views/identity/administration/Users",
100100
"allowedRoles": ["admin", "editor", "readonly"]
101101
},
102+
{
103+
"path": "/identity/administration/risky-users",
104+
"name": "Risky Users",
105+
"component": "views/identity/administration/RiskyUsers",
106+
"allowedRoles": ["admin", "editor", "readonly"]
107+
},
102108
{
103109
"path": "/identity/administration/devices",
104110
"name": "Devices",
@@ -206,6 +212,12 @@
206212
"component": "views/identity/reports/AzureADConnectReport",
207213
"allowedRoles": ["admin", "editor", "readonly"]
208214
},
215+
{
216+
"path": "/identity/reports/risk-detections",
217+
"name": "Risk Detections",
218+
"component": "views/identity/reports/RiskDetections",
219+
"allowedRoles": ["admin", "editor", "readonly"]
220+
},
209221
{
210222
"path": "/tenant",
211223
"name": "Tenant",

src/store/features/app.js

+5
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ const initialState = {
1414
defaultColumns: {},
1515
newUserDefaults: {},
1616
recentPages: [],
17+
setupCompleted: false,
1718
}
1819

1920
export const appSlice = createSlice({
@@ -62,6 +63,9 @@ export const appSlice = createSlice({
6263
setRecentPages: (state, action) => {
6364
state.recentPages = action.payload?.recentPages
6465
},
66+
setSetupCompleted: (state, action) => {
67+
state.setupCompleted = action.payload?.setupCompleted
68+
},
6569
},
6670
})
6771

@@ -80,6 +84,7 @@ export const {
8084
setDefaultColumns,
8185
setNewUserDefaults,
8286
setRecentPages,
87+
setSetupCompleted,
8388
} = appSlice.actions
8489

8590
export default persistReducer(

0 commit comments

Comments
 (0)