(ActionEvent e)
| 23 | list.add(jMenuItem); |
| 24 | jMenuItem.addActionListener(new ActionListener() { |
| 25 | @Override |
| 26 | public void actionPerformed(ActionEvent e) { |
| 27 | ConfigDlg cfd = new ConfigDlg(); |
| 28 | cfd.show(); |
| 29 | |
| 30 | if(Config.isIsInject()) { |
| 31 | IHttpRequestResponse[] messages = invocation.getSelectedMessages(); |
| 32 | byte[] req = messages[0].getRequest(); |
| 33 | IHttpService httpService = messages[0].getHttpService(); |
| 34 | String host = httpService.getHost().replace(".", "_"); |
| 35 | int port = httpService.getPort(); |
| 36 | |
| 37 | SimpleDateFormat df = new SimpleDateFormat("yyyyMMddHHmmss"); |
| 38 | String data = df.format(new Date()); |
| 39 | String requstFilename = String.format("%s_%s_%s.req", host, port, data); |
| 40 | String reqFilePath = Util.getTempReqName(requstFilename); |
| 41 | Util.writeFile(req, reqFilePath); |
| 42 | new Thread(new SqlmapStarter()).start(); |
| 43 | Config.setIsInject(false); |
| 44 | } |
| 45 | } |
| 46 | }); |
| 47 | return list; |
| 48 | } |
nothing calls this directly
no test coverage detected