A free, open-source alternative to Burp Suite: an intercepting proxy and web app security testing suite with Repeater, Intruder, Collaborator and a built-in OWASP ZAP scanner. Linux, AGPL-3.0.
Java application-securityappsecbug-bountyburp-alternativeburp-suitedasthttp-proxyinfosecintercepting-proxyjavaowaspowasp-zappenetration-testingpentestingsecuritysecurity-toolsvulnerability-scannerweb-application-securityweb-security
New scan: the step list, the scan type cards and the configuration list look as the reference's
scottsturrock9fab1fc30fdc
diff --git a/src/opensuite/dashboard/NewScanWizard.java b/src/opensuite/dashboard/NewScanWizard.javaindex 23d61f4..f4db9db 100644--- a/src/opensuite/dashboard/NewScanWizard.java+++ b/src/opensuite/dashboard/NewScanWizard.java@@ -63,8 +63,7 @@ public class NewScanWizard extends JDialog {content.add(buildScanType(), "Scan type");content.add(buildScanDetails(ctx), "Scan details");- content.add(stepPanel("Scan configuration",- "Select the type of scan configuration you want to run. You can adjust it as needed.", webConfig), "Scan configuration");+ content.add(stepPanel("Scan configuration", null, webConfig), "Scan configuration");webConfig.requireChoice();apiConfig.requireChoice();login = new ApplicationLoginPanel(ctx, this::targetUrls);@@ -72,17 +71,17 @@ public class NewScanWizard extends JDialog {content.add(stepPanel("Resource pool", "Specify the resources the scan may use.", resourcePool), "Resource pool");content.add(stepPanel("API definition", "Upload the definition of the API to scan.", apiDefinition), "API definition");content.add(stepPanel("API details", "Endpoints included in the scan.", apiDetails), "API details");- content.add(stepPanel("Scan configuration ",- "Select the audit configuration for the API scan.", apiConfig), "API configuration");+ content.add(stepPanel("Scan configuration ", null, apiConfig), "API configuration");apiDefinition.onChange(() -> apiDetails.show(apiDefinition.endpoints(), apiDefinition.source(), apiDefinition.baseUrl()));railPanel.setLayout(new BoxLayout(railPanel, BoxLayout.Y_AXIS));- railPanel.setBackground(Theme.SURFACE);- railPanel.setBorder(BorderFactory.createMatteBorder(0, 0, 0, 1, Ui.GRID));+ // The step list is a narrow white column with a line down its right side, as the reference's.+ railPanel.setBackground(Theme.CARD);JPanel railWrap = new JPanel(new BorderLayout());railWrap.add(railPanel, BorderLayout.NORTH);- railWrap.setBackground(Theme.SURFACE);- railWrap.setPreferredSize(new Dimension(152 + 8 * Ui.fontGrowth(), 10));+ railWrap.setBackground(Theme.CARD);+ railWrap.setBorder(BorderFactory.createMatteBorder(0, 0, 0, 1, Ui.GRID));+ railWrap.setPreferredSize(new Dimension(RAIL_WIDTH + 8 * Ui.fontGrowth(), 10));buildRail();setLayout(new BorderLayout());@@ -147,17 +146,17 @@ public class NewScanWizard extends JDialog {for (int i = 0; i < steps.length; i++) {final int idx = i;JToggleButton b = new JToggleButton(- "<html><div style='text-align:center'>" + steps[i].replace(" ", "<br>") + "</div></html>");+ "<html><div style='text-align:center'>" + railLabel(steps[i]) + "</div></html>");b.setFont(Ui.PLAIN);b.setFocusable(false);b.setContentAreaFilled(false);b.setOpaque(true);- b.setBackground(Theme.SURFACE);+ b.setBackground(Theme.CARD);b.setHorizontalTextPosition(SwingConstants.CENTER);b.setVerticalTextPosition(SwingConstants.BOTTOM);- b.setBorder(Ui.pad(12, 14, 12, 14));+ b.setBorder(Ui.pad(12, 4, 12, 4));b.setAlignmentX(Component.CENTER_ALIGNMENT);- b.setMaximumSize(new Dimension(150, 80));+ b.setMaximumSize(new Dimension(Integer.MAX_VALUE, 80 + 6 * Ui.fontGrowth()));b.addActionListener(e -> selectStep(idx));g.add(b);rail[i] = b;@@ -188,7 +187,7 @@ public class NewScanWizard extends JDialog {for (int k = 0; k < rail.length; k++) {boolean on = k == step;rail[k].setSelected(on);- rail[k].setBackground(on ? Ui.ACCENT : Theme.SURFACE);+ rail[k].setBackground(on ? Theme.CONTROL : Theme.CARD);rail[k].setForeground(on ? Color.WHITE : Theme.TEXT);rail[k].setIcon(railIcon(icons[k], on ? Color.WHITE : Theme.MUTED));}@@ -203,45 +202,73 @@ public class NewScanWizard extends JDialog {private JComponent buildScanType() {ButtonGroup g = new ButtonGroup();g.add(typeCrawlAudit); g.add(typeCrawl); g.add(typeApiOnly);- JPanel cardsRow = new JPanel(new GridLayout(1, 3, 16, 0));+ JPanel cardsRow = new JPanel(new GridLayout(1, 3, 10, 0));cardsRow.setOpaque(false);cardsRow.add(typeCard(typeCrawlAudit, "Crawl and audit",- "Maps the attack surface and identifies vulnerabilities. Scans the web application and any detected APIs."));+ "Maps the attack surface and identifies vulnerabilities. Scans the web application and any detected APIs"));cardsRow.add(typeCard(typeCrawl, "Crawl",- "Maps the attack surface of the web application and any detected APIs."));+ "Maps the attack surface of the web application and any detected APIs"));cardsRow.add(typeCard(typeApiOnly, "API-only scan",- "Offers additional configuration options. Scans the endpoints of an uploaded API definition."));+ "Offers additional configuration options"));JPanel wrap = new JPanel(new BorderLayout());wrap.setOpaque(false);wrap.add(cardsRow, BorderLayout.NORTH);- return stepPanel("Scan type", "Select the type of scan to run.", wrap);+ return stepPanel("Scan type", "Select the type of scan you'd like to run.", wrap);}+ private static final int RAIL_WIDTH = 112;++ /** A step's name as the list shows it: on one line when short, else broken after its first word. */+ static String railLabel(String step) {+ String t = step.strip();+ int sp = t.indexOf(' ');+ return sp < 0 || t.length() <= 12 ? t : t.substring(0, sp) + "<br>" + t.substring(sp + 1);+ }++ /**+ * One scan type to choose: a rounded grey card with its dot to the left of+ * its name and description. The chosen card is white with a thin blue+ * line around it, as the reference draws it.+ */private JComponent typeCard(JRadioButton radio, String title, String desc) {- JPanel card = new JPanel(new BorderLayout(0, 6));- card.setBackground(Theme.BG);- card.setBorder(BorderFactory.createCompoundBorder(BorderFactory.createLineBorder(Ui.GRID), Ui.pad(14, 14, 14, 14)));- JPanel head = new JPanel(new FlowLayout(FlowLayout.LEFT, 6, 0));- head.setOpaque(false);+ JPanel card = new JPanel(new BorderLayout(14, 0)) {+ @Override protected void paintComponent(Graphics g0) {+ Graphics2D g = (Graphics2D) g0.create();+ g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);+ g.setRenderingHint(RenderingHints.KEY_STROKE_CONTROL, RenderingHints.VALUE_STROKE_PURE);+ boolean on = radio.isSelected();+ g.setColor(on ? Theme.CARD : Theme.SURFACE);+ g.fill(new java.awt.geom.RoundRectangle2D.Double(0.5, 0.5, getWidth() - 1, getHeight() - 1, 12, 12));+ if (on) {+ g.setColor(Theme.CONTROL);+ g.draw(new java.awt.geom.RoundRectangle2D.Double(0.5, 0.5, getWidth() - 1, getHeight() - 1, 12, 12));+ }+ g.dispose();+ }+ };+ card.setOpaque(false);+ card.setBorder(Ui.pad(26, 24, 16, 22));radio.setOpaque(false);- head.add(radio);- head.add(Ui.bold(title));- card.add(head, BorderLayout.NORTH);- card.add(Ui.note(desc), BorderLayout.CENTER);- card.setPreferredSize(new Dimension(230, 110));+ JPanel dot = new JPanel(new GridBagLayout());+ dot.setOpaque(false);+ dot.add(radio);+ JTextArea text = Ui.note(desc);+ text.setForeground(Theme.TEXT);+ JPanel words = new JPanel(new BorderLayout(0, 12));+ words.setOpaque(false);+ JLabel name = Ui.bold(title);+ name.setFont(name.getFont().deriveFont(name.getFont().getSize2D() + 1f));+ words.add(name, BorderLayout.NORTH);+ words.add(text, BorderLayout.CENTER);+ card.add(dot, BorderLayout.WEST);+ card.add(words, BorderLayout.CENTER);+ card.setPreferredSize(new Dimension(230, 146 + 10 * Ui.fontGrowth()));Ui.wholeCardSelects(card, radio);- radio.addActionListener(e -> { onTypeChosen(); typeCards.forEach(Runnable::run); });- // The chosen card is outlined, so the choice reads from the card and not only from its dot.- Runnable look = () -> card.setBorder(BorderFactory.createCompoundBorder(- BorderFactory.createLineBorder(radio.isSelected() ? Ui.ACCENT : Ui.GRID, radio.isSelected() ? 2 : 1),- radio.isSelected() ? Ui.pad(13, 13, 13, 13) : Ui.pad(14, 14, 14, 14)));- typeCards.add(look);- radio.addItemListener(e -> typeCards.forEach(Runnable::run));+ radio.addActionListener(e -> onTypeChosen());+ radio.addItemListener(e -> card.repaint());return card;}- private final java.util.List<Runnable> typeCards = new java.util.ArrayList<>();-/** A scan type was chosen: show its steps and enable Scan. */private void onTypeChosen() {String[] want = typeApiOnly.isSelected() ? API_STEPS : WEB_STEPS;@@ -420,7 +447,7 @@ public class NewScanWizard extends JDialog {JPanel titles = new JPanel(new BorderLayout());titles.setOpaque(false);titles.add(Ui.heading(title), BorderLayout.NORTH);- titles.add(Ui.note(subtitle), BorderLayout.CENTER);+ if (subtitle != null) titles.add(Ui.note(subtitle), BorderLayout.CENTER);p.add(titles, BorderLayout.NORTH);p.add(body, BorderLayout.CENTER);return p;diff --git a/src/opensuite/dashboard/ScanConfigPanel.java b/src/opensuite/dashboard/ScanConfigPanel.javaindex 85cb493..a440068 100644--- a/src/opensuite/dashboard/ScanConfigPanel.java+++ b/src/opensuite/dashboard/ScanConfigPanel.java@@ -139,6 +139,10 @@ public final class ScanConfigPanel extends JPanel {// Header row: Save / Load on the right, preset combo beneath the note.JButton save = Ui.button("Save", "Save this configuration to the library");JButton load = Ui.button("Load", "Load a configuration from the library");+ save.setIcon(Glyphs.save(15, Theme.ICON));+ load.setIcon(Glyphs.download(15, Theme.ICON));+ save.setIconTextGap(8);+ load.setIconTextGap(8);save.addActionListener(e -> save());load.addActionListener(e -> load());JPanel actions = new JPanel(new FlowLayout(FlowLayout.RIGHT, 6, 0));@@ -147,8 +151,19 @@ public final class ScanConfigPanel extends JPanel {preset.setFont(Ui.PLAIN);preset.setRenderer(new PresetRenderer());- preset.setMaximumRowCount(6);- preset.setPreferredSize(new Dimension(Ui.em(580), 44)); // wide enough for the longest description+ preset.setMaximumRowCount(PRESETS.size()); // every choice shows at once, with no scroll bar+ preset.setPreferredSize(new Dimension(Ui.em(300), 28 + 2 * Ui.fontGrowth())); // one line closed; it takes the page's width+ // All five show at once, so the list has no scroll bar to draw.+ preset.addPopupMenuListener(new javax.swing.event.PopupMenuListener() {+ @Override public void popupMenuWillBecomeVisible(javax.swing.event.PopupMenuEvent e) {+ if (preset.getAccessibleContext().getAccessibleChild(0) instanceof javax.swing.plaf.basic.ComboPopup popup+ && SwingUtilities.getAncestorOfClass(JScrollPane.class, popup.getList()) instanceof JScrollPane scroll) {+ scroll.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_NEVER);+ }+ }+ @Override public void popupMenuWillBecomeInvisible(javax.swing.event.PopupMenuEvent e) { }+ @Override public void popupMenuCanceled(javax.swing.event.PopupMenuEvent e) { }+ });preset.addActionListener(e -> onPreset());JPanel top = new JPanel(new BorderLayout(0, 6));@@ -157,12 +172,13 @@ public final class ScanConfigPanel extends JPanel {head.setOpaque(false);head.add(Ui.note(mode == Mode.PASSIVE_CRAWL? "Select how the live passive crawl adds items to the site map."- : "Select the scan configuration you want to run. Choose Custom to adjust every setting."), BorderLayout.CENTER);+ : "Select the type of scan configuration you want to run, or load an existing configuration. You can adjust the configuration as needed."), BorderLayout.CENTER);head.add(actions, BorderLayout.EAST);top.add(head, BorderLayout.NORTH);- JPanel presetRow = new JPanel(new FlowLayout(FlowLayout.LEFT, 0, 0));+ JPanel presetRow = new JPanel(new BorderLayout());presetRow.setOpaque(false);- presetRow.add(preset);+ presetRow.setBorder(Ui.pad(8, 0, 0, 0));+ presetRow.add(preset, BorderLayout.CENTER);if (mode != Mode.PASSIVE_CRAWL) top.add(presetRow, BorderLayout.CENTER);add(top, BorderLayout.NORTH);@@ -503,29 +519,56 @@ public final class ScanConfigPanel extends JPanel {}}- /** Icon + title + grey description, both in the list and in the closed combo. */+ /**+ * A configuration to choose. In the open list each is its own icon, its+ * name in bold and a line saying what it is for, with a rule under it;+ * the closed box shows the name alone on one line.+ */private static final class PresetRenderer extends JPanel implements ListCellRenderer<Preset> {private final JLabel title = Ui.bold("");private final JLabel desc = Ui.label("");private final JLabel icon = new JLabel();+ private final JLabel closed = Ui.label("");+ private final JPanel open = new JPanel(new BorderLayout(12, 0));PresetRenderer() {- super(new BorderLayout(8, 0));- setBorder(Ui.pad(4, 6, 4, 6));- JPanel text = new JPanel(new GridLayout(2, 1));+ super(new BorderLayout());+ JPanel text = new JPanel(new GridLayout(2, 1, 0, 6));text.setOpaque(false);- desc.setForeground(Theme.MUTED);text.add(title); text.add(desc);- add(icon, BorderLayout.WEST);- add(text, BorderLayout.CENTER);+ icon.setVerticalAlignment(SwingConstants.TOP);+ icon.setBorder(Ui.pad(1, 0, 0, 0));+ open.setOpaque(false);+ open.add(icon, BorderLayout.WEST);+ open.add(text, BorderLayout.CENTER);+ setOpaque(true);}@Override public Component getListCellRendererComponent(JList<? extends Preset> list, Preset v, int i, boolean sel, boolean focus) {- title.setText(v == null ? "Select a scan configuration" : v.name());- desc.setText(v == null ? "Choose a preset, or Custom to adjust every setting." : v.description());- icon.setIcon(v == null ? null : Glyphs.bolt(16, sel ? Color.WHITE : Ui.ACCENT));- setBackground(sel && v != null ? Ui.SELECTION : Theme.BG);- setOpaque(true);- title.setForeground(v == null ? Theme.MUTED : Theme.TEXT);- desc.setForeground(Theme.MUTED);+ removeAll();+ if (i < 0) {+ // The closed box.+ closed.setText(v == null ? "Select a scan configuration" : v.name());+ closed.setForeground(Theme.TEXT);+ setBorder(Ui.pad(0, 2, 0, 2));+ setBackground(Theme.CARD);+ add(closed, BorderLayout.CENTER);+ return this;+ }+ title.setText(v.name());+ desc.setText(v.description());+ title.setForeground(Theme.TEXT);+ desc.setForeground(Theme.TEXT);+ icon.setIcon(switch (v.name()) {+ case "Lightweight" -> Glyphs.lightweight(18, Theme.TEXT);+ case "Fast" -> Glyphs.fast(18, Theme.TEXT);+ case "Balanced" -> Glyphs.balanced(18, Theme.TEXT);+ case "Deep" -> Glyphs.deep(18, Theme.TEXT);+ default -> Glyphs.sliders(18, Theme.TEXT);+ });+ boolean last = i == list.getModel().getSize() - 1;+ setBorder(BorderFactory.createCompoundBorder(+ BorderFactory.createMatteBorder(0, 0, last ? 0 : 1, 0, Ui.GRID), Ui.pad(16, 14, 16, 14)));+ setBackground(sel ? Theme.CONTROL_TINT : Theme.CARD);+ add(open, BorderLayout.CENTER);return this;}}diff --git a/src/opensuite/ui/Glyphs.java b/src/opensuite/ui/Glyphs.javaindex 54c2ec4..5f1510f 100644--- a/src/opensuite/ui/Glyphs.java+++ b/src/opensuite/ui/Glyphs.java@@ -246,6 +246,134 @@ public final class Glyphs {});}+ // ---- scan configurations ----++ /** Speed lines running into a clock: the quickest scan. */+ public static Icon lightweight(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new Ellipse2D.Double(s * 0.42, s * 0.22, s * 0.5, s * 0.5));+ g.draw(new Line2D.Double(s * 0.67, s * 0.34, s * 0.67, s * 0.48));+ g.draw(new Line2D.Double(s * 0.67, s * 0.48, s * 0.77, s * 0.54));+ g.draw(new Line2D.Double(s * 0.06, s * 0.3, s * 0.3, s * 0.3));+ g.draw(new Line2D.Double(s * 0.12, s * 0.47, s * 0.3, s * 0.47));+ g.draw(new Line2D.Double(s * 0.06, s * 0.64, s * 0.3, s * 0.64));+ });+ }++ /** Two triangles pointing right: fast forward. */+ public static Icon fast(int size, Color c) {+ return make(size, c, (g, s) -> {+ for (double x : new double[]{0.08, 0.5}) {+ Path2D p = new Path2D.Double();+ p.moveTo(s * x, s * 0.24); p.lineTo(s * (x + 0.4), s * 0.5); p.lineTo(s * x, s * 0.76); p.closePath();+ g.draw(p);+ }+ });+ }++ /** A pair of scales: balanced. */+ public static Icon balanced(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new Line2D.Double(s * 0.5, s * 0.12, s * 0.5, s * 0.86));+ g.draw(new Line2D.Double(s * 0.32, s * 0.86, s * 0.68, s * 0.86));+ g.draw(new Line2D.Double(s * 0.14, s * 0.26, s * 0.86, s * 0.26));+ for (double x : new double[]{0.2, 0.8}) {+ g.draw(new Line2D.Double(s * x, s * 0.26, s * (x - 0.14), s * 0.56));+ g.draw(new Line2D.Double(s * x, s * 0.26, s * (x + 0.14), s * 0.56));+ g.draw(new java.awt.geom.Arc2D.Double(s * (x - 0.14), s * 0.44, s * 0.28, s * 0.24, 180, 180, java.awt.geom.Arc2D.OPEN));+ }+ });+ }++ /** A line sinking below the surface: deep. */+ public static Icon deep(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new Line2D.Double(s * 0.5, s * 0.1, s * 0.5, s * 0.34));+ g.draw(new Line2D.Double(s * 0.38, s * 0.24, s * 0.5, s * 0.36));+ g.draw(new Line2D.Double(s * 0.62, s * 0.24, s * 0.5, s * 0.36));+ g.draw(new java.awt.geom.Arc2D.Double(s * 0.1, s * 0.2, s * 0.8, s * 0.56, 200, 140, java.awt.geom.Arc2D.OPEN));+ g.draw(new Line2D.Double(s * 0.1, s * 0.9, s * 0.9, s * 0.9));+ });+ }++ /** Three sliders: settings set by hand. */+ public static Icon sliders(int size, Color c) {+ return make(size, c, (g, s) -> {+ double[] xs = {0.2, 0.5, 0.8}, knobs = {0.62, 0.34, 0.56};+ for (int i = 0; i < 3; i++) {+ g.draw(new Line2D.Double(s * xs[i], s * 0.1, s * xs[i], s * 0.9));+ g.draw(new Line2D.Double(s * (xs[i] - 0.11), s * knobs[i], s * (xs[i] + 0.11), s * knobs[i]));+ }+ });+ }++ // ---- files and the clipboard ----++ /** A disk: save. */+ public static Icon save(int size, Color c) {+ return make(size, c, (g, s) -> {+ Path2D p = new Path2D.Double();+ p.moveTo(s * 0.14, s * 0.14); p.lineTo(s * 0.7, s * 0.14); p.lineTo(s * 0.86, s * 0.3);+ p.lineTo(s * 0.86, s * 0.86); p.lineTo(s * 0.14, s * 0.86); p.closePath();+ g.draw(p);+ g.draw(new java.awt.geom.Rectangle2D.Double(s * 0.3, s * 0.54, s * 0.4, s * 0.32));+ g.draw(new Line2D.Double(s * 0.32, s * 0.14, s * 0.32, s * 0.34));+ g.draw(new Line2D.Double(s * 0.32, s * 0.34, s * 0.62, s * 0.34));+ g.draw(new Line2D.Double(s * 0.62, s * 0.34, s * 0.62, s * 0.14));+ });+ }++ /** An arrow coming down into a tray: load. */+ public static Icon download(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new Line2D.Double(s * 0.5, s * 0.1, s * 0.5, s * 0.6));+ g.draw(new Line2D.Double(s * 0.3, s * 0.42, s * 0.5, s * 0.62));+ g.draw(new Line2D.Double(s * 0.7, s * 0.42, s * 0.5, s * 0.62));+ g.draw(new Path2D.Double() {{+ moveTo(s * 0.12, s * 0.62); lineTo(s * 0.12, s * 0.86); lineTo(s * 0.88, s * 0.86); lineTo(s * 0.88, s * 0.62);+ }});+ });+ }++ /** Scissors: cut. */+ public static Icon scissors(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new Ellipse2D.Double(s * 0.1, s * 0.14, s * 0.24, s * 0.24));+ g.draw(new Ellipse2D.Double(s * 0.1, s * 0.62, s * 0.24, s * 0.24));+ g.draw(new Line2D.Double(s * 0.31, s * 0.33, s * 0.9, s * 0.8));+ g.draw(new Line2D.Double(s * 0.31, s * 0.67, s * 0.9, s * 0.2));+ });+ }++ /** A clipboard: paste. */+ public static Icon clipboard(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new java.awt.geom.RoundRectangle2D.Double(s * 0.18, s * 0.2, s * 0.64, s * 0.7, s * 0.12, s * 0.12));+ g.draw(new java.awt.geom.RoundRectangle2D.Double(s * 0.34, s * 0.1, s * 0.32, s * 0.2, s * 0.1, s * 0.1));+ });+ }++ /** Two arrows chasing each other round: change, swap. */+ public static Icon swap(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new java.awt.geom.Arc2D.Double(s * 0.14, s * 0.14, s * 0.72, s * 0.72, 30, 150, java.awt.geom.Arc2D.OPEN));+ g.draw(new java.awt.geom.Arc2D.Double(s * 0.14, s * 0.14, s * 0.72, s * 0.72, 210, 150, java.awt.geom.Arc2D.OPEN));+ g.draw(new Line2D.Double(s * 0.14, s * 0.5, s * 0.06, s * 0.3));+ g.draw(new Line2D.Double(s * 0.14, s * 0.5, s * 0.32, s * 0.38));+ g.draw(new Line2D.Double(s * 0.86, s * 0.5, s * 0.94, s * 0.7));+ g.draw(new Line2D.Double(s * 0.86, s * 0.5, s * 0.68, s * 0.62));+ });+ }++ /** A ring with a plus in it: add a payload. */+ public static Icon ringPlus(int size, Color c) {+ return make(size, c, (g, s) -> {+ g.draw(new Ellipse2D.Double(s * 0.1, s * 0.1, s * 0.8, s * 0.8));+ g.draw(new Line2D.Double(s * 0.5, s * 0.3, s * 0.5, s * 0.7));+ g.draw(new Line2D.Double(s * 0.3, s * 0.5, s * 0.7, s * 0.5));+ });+ }+/** A lightning bolt: the suite accent mark used for custom actions. */public static Icon bolt(int size, Color c) {return make(size, c, (g, s) -> {