Jump to content

Search the Community

Showing results for 'Self Signed certificate'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • uniGUI Public
    • Announcements
    • General
    • Feature Requests
    • Installation
    • Deployment
    • Other Platforms
  • Licensing
    • Licensing
    • Ordering uniGUI
  • Bug Reports
    • Active Reports
    • Closed Reports
    • Old Bug Reports
  • uniGUI Development
    • General Development
    • uniGUI Releases & Roadmaps
    • Utilities
  • Mobile Platform
    • uniGUI Mobile
    • Mobile Browsers
  • Users Area
    • Sample Projects
    • Components and Code Samples
    • Third Party Components
  • Non-English
    • Non-English
  • Miscellaneous
    • Hosting
    • Server Security
    • Jobs

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests

  1. i create a array of tuniPanels with meine_marker[x]:=TUniPanel.Create(self); i give the unipanels different css classes with UniSession.AddJS(meine_marker[x].JSName + '.addCls(''marker_1'');'); is it possible to give the unipanel different backgrounds?? i tryed out in css-file: background-image: url(bullet.png); .. but doesnt work... is it possible with "UniSession.AddJS(meine_marker[x].JSName +"... and somting else? ThanX for help
  2. Self-generated with help of UniURLFrame1.HTML.Text :=
  3. How are you Andyhill ? Hoping you feel good... Did you try http://www.unigui.com/doc/online_help/getting-a-ssl-certificate-from.htm Maybe the copy/past of the 2 .pem files is confused or change them : root.pem = gd_bundle-g2-g1.crt cert.pem = 98d81da6dfe2095b.crt
  4. Yes it is possible Solution : 1. Edit the host file : c:\windows\system32\driver\ets\host 2. Add this line for example: 192.168.1.11 mysite.com save it (192.168.1.11 is your local server) 3. Do the same on all your PC local machines. 4. Create on your server a p12 Certificate for mysite.com (as described above step3 + 4) powershell > mkcert -pkcs12 mysite.com 5. Install it on both : your server and client PC 6. Run your app from all local pc : https://mysite.com is secure ____ PS: don't ask me for mobile device (android). I don't know...
  5. We win the first half of the match. Remains the second half : Using our SSL on Android via wifi. All google topics say that it's enough to import this p12 Certificat on the Mobile (Android device). I tried....But steel the cadet no Secure appears As i launch the app from my Mobile like : https://192.168.1.11:8077 and not https://localhost:8077 - So, I created a new p12 Certificat (only on server) 192.168.1.11.p12 - And test it first, on my others windows PC (local network) : just import it as described on step 4 above : Touche Win + R key: mmc ) Then Open browser with : https://192.168.1.11:8077 And....Yes the cadet is Secure. - But when i did the same on Android....Humm......Not secure I saw many google search : "importing trust certificate on android phone" No result Any help is welcome Thx
  6. ok. first - thanks to RON. i finally get the answer. in one of Thousands of posts i read, i found that : Accessing localhost If your website needs to issue requests to localhost, then you just need to upgrade your website to HTTPS. this was in : https://developer.chrome.com/blog/private-network-access-update/ since my test site was HTTP://HanibaalDemos:8077 chrome did not allow CORS. i bought new SSL certificate, add set SSL capability to the Site - and Vuala - it work. to run the WebService From The client side, Just Var ThisName : String; begin ThisName := Self.Name; JustWriteToLog('btnAddFilesFromListClick - Self.Name = ' + ThisName); JustWriteToLog('Before UniSession.AddJS($.get("http://127.0.0.1:8989/GetMi"...'); UniSession.AddJS('$.ajaxSetup({headers: { "Access-Control-Allow-Origin": "*" }});'); UniSession.AddJS('$.get("http://127.0.0.1:8989/GetMi", function( data ){' + ' ajaxRequest(' + ThisName + '.form, ["test"],{headers: { "Access-Control-Allow-Origin": "*" }}, { response : data });}); '); JustWriteToLog('After UniSession.AddJS($.get("http://127.0.0.1:8989/GetMi"...'); end; and Add Ajax Event For "Test" : procedure TSendMailFrm.UniFormAjaxEvent(Sender: TComponent; EventName: string; Params: TUniStrings); begin JustWriteToLog('EventName : ' + EventName); JustWriteToLog('Params : ' + Params.Text); if sameText(EventName, 'test') then edToList.Text:=Params.Values['response']; end; at the server side : in the WebModuleBeforeDispatch Event - procedure TWebModule1.WebModuleBeforeDispatch(Sender: TObject; Request: TWebRequest; Response: TWebResponse; var Handled: Boolean); begin JustWriteToLog('On WebModuleBeforeDispatch'); Response.CustomHeaders.Values['Access-Control-Allow-Origin'] := '*'; Response.CustomHeaders.Values['Access-Control-Allow-Headers'] := '*'; Response.CustomHeaders.Values['Access-Control-Allow-Methods'] := 'GET, POST, PUT, DELETE, OPTIONS'; Response.CustomHeaders.Values['Access-Control-Allow-Credentials'] := 'true'; Response.CustomHeaders.Values['Access-Control-Allow-Private-Network'] := '*'; Response.CustomHeaders.Values['Access-Control-Expose-Headers'] := ''; if Trim(Request.GetFieldByName('Access-Control-Request-Headers')) <> '' then begin JustWriteToLog('On WebModuleBeforeDispatch - Trim(Request.GetFieldByName(Access-Control-Request-Headers))'); //Response.SetCustomHeader('Access-Control-Allow-Headers', Request.GetFieldByName('Access-Control-Request-Headers')); Response.CustomHeaders.Values['Access-Control-Allow-Headers'] := Request.GetFieldByName('Access-Control-Request-Headers'); Handled := True; end; if SameText(Request.Method, 'OPTIONS') then begin JustWriteToLog('On WebModuleBeforeDispatch - if SameText(Request.Method, Option)'); Handled := True; end; if FServerFunctionInvokerAction <> nil then begin JustWriteToLog('On WebModuleBeforeDispatch - if FServerFunctionInvokerAction <> nil'); FServerFunctionInvokerAction.Enabled := AllowServerFunctionInvoker; end; end; now - we gat the backend door to control the local PC components/data from our cloud site
  7. Hello, Please provide more information. What certificate are you using? Self-signed?
  8. With buffer config (1000 ms): Self.ClientEvents.ExtEvents.Values['afterrender'] := 'function afterrender(sender, eOpts){sender.on({mousemove: function(){ajaxRequest('+ Self.OwnerWebForm.JSName +', "_mousemove", {frameName: "'+ Self.Name +'"})}, buffer: 1000})}';
  9. For example, try. In your frame, on the OnCreate event, the event will be sent to the owner form (you can also configure the buffer config, which will invoke the event after the specified time...) Self.ClientEvents.ExtEvents.Values['afterrender'] := 'function afterrender(sender, eOpts){sender.on("mousemove", function(){ajaxRequest('+ Self.OwnerWebForm.JSName +', "_mousemove", {frameName: "'+ Self.Name +'"})})}';
  10. Oh yes , i'm aware of that. If i compile the code in 32 bits then it works with both a self signed and a godaddy's certificate. But in 64 bits it doesn't work. it is giving the error i start this thread with. So any suggestions will be appreciated! Thanks in advance
  11. Sherzod

    Clear Button

    Try this approach, added dirtychange event: procedure TMainForm.UniFormCreate(Sender: TObject); var I: Integer; begin for I := 0 to Self.ComponentCount - 1 do begin if Self.Components[I].ClassType = TUniDBEdit then begin with TUniDBEdit(Self.Components[I]) do begin if ClearButton then begin JSInterface.JSAddListener('afterrender', 'function(cmp){cmp.getTrigger("clear").hide()}'); JSInterface.JSAddListener('focus', 'function(cmp){if (cmp.getValue()!="") cmp.getTrigger("clear").show()}'); JSInterface.JSAddListener('blur', 'function(cmp){cmp.getTrigger("clear").hide()}'); JSInterface.JSAddListener('dirtychange', 'function(cmp){cmp.getTrigger("clear").hide()}'); //<-------- end; end; end; end; end;
  12. Turns out that perhaps you could make a self signed certificate to avoid the pop-up message: Will try tomorrow. Lost a lot of time looking for a solution. Such information is not very clear in their website. Not even clear if self-signed certificates works or just trusted by a secure entities to a website only . https://qz.io/wiki/signing-messages Not verfy clear and even the presenter make some mistakes. Best source is this link below: https://ijustlearnedsomethingnewtoday.blogspot.com/2017/04/using-self-signed-certificates-with-qz.html I will keep you guys posted if it worked.
  13. { TUniLabelHelper } procedure TUniLabelHelper.ConfigureIcon(Icon: String); begin Self.ClientEvents.UniEvents.Values['ajaxCallback'] := 'function ajaxCallback(sender, response) { try {sender.setDisabled(false)} catch(err){}; }'; with Self.JSInterface do begin JSConfig('_text', [Self.Caption]); JSConfig('_iconCls', [Icon]); JSAddListener('disable', 'function(){this.setHtml(''<i class="fas fa-sync fa-spin"></i>'')}'); JSAddListener('enable', 'function(){this.setHtml(this.getConfig("_iconCls")); this.setHtml(this.getConfig("_text"))}'); JSAddListener('click', 'function(){this.setDisabled(true);}'); end; end; Self.lbAtualizarDashBoard.ConfigureIcon('<i class="fas fa-chart-line"></i>'); My fault, I had forgotten about this routine
  14. Do you have a self-signed certificate?
  15. picyka

    UniTimer

    function hasTask(host, token) { try { var Http = new XMLHttpRequest(); Http.open("GET", host, false); Http.setRequestHeader('Authorization', 'Bearer ' + token); Http.send(); if (Http.status == 200) { console.log('Buscado tarefa...'); if (Http.responseText.includes("true")) { top.ajaxRequest(top.MainForm.form, '_task', ['value=true']); } } } catch (err) { console.log('Erro Tarefa:' + err); } }; procedure TUniMainModule.ExecuteTimerTarefa; begin {180000 - 3 MINUTOS} try var lUrl := Self.URL_EX_API + 'END POINT'; var lJsString := 'var TimerTarefa = setInterval(function () {hasTask(' + QuotedStr(lUrl) + ',' + QuotedStr(Self.TOKEN_API) + ');}, 180000);'; UniSession.JSCode(lJsString); except on E: Exception do TMessageUtils.Error(E.Message); end; procedure TMainForm.UniFormAjaxEvent(Sender: TComponent; EventName: string; Params: TUniStrings); begin if SameStr(EventName, '_task') then begin TToastUtils.Aviso('Tarefa encontrada, ja vou te mostrar!', False, 'Aviso de Tarefa',8000); UniTimerTarefas.Enabled := True; end; end; I will post here my solution, as I use API it became easier to solve. Ajax only fires when it's really needed.
  16. 1. Rename STAR_sisblu_com_br.ca-bundle -> ca_bundle.crt 2. Rename STAR_sisblu_com_br.crt -> certificate.crt 3. Rename STAR_sisblu_com_br.key ->key.pem 4. Install OpenSSL www.hacom.de/temp/Win64OpenSSL_Light-1_1_1k.exe 5. In OpenSSL commandline go to directory, where the files are saved and call : openssl x509 -in certificate.crt -out cert.pem -outform PEM openssl x509 -in ca_bundle.crt -out root.pem -outform PEM 6. Copy the files key.pem, cert.pem and root.pem (certificate.crt, ca_bundle.crt are optional) in to appropriate directory
  17. how to use command uniedit---> Self.SelStart := Length(Self.Text); Self.SelLength := 0; And method change not found class list. procedure Change; override; problem - 1 Complete unit: //----------------------------------- Autocomplete edit-------------------------------------------------// unit AutocompleteEdit; interface uses Windows , Classes , Vcl.StdCtrls , SysUtils , StrUtils , Messages ,uniEdit ,uniGUIBaseClasses ,uniGUIClasses; const MSG_HIDEWORDLIST = WM_USER + 222; type TAutocompleteEdit=class(Tuniedit) private FWordList: TListBox; FCaretPos: Integer; FWordListHeight: Integer; FWordListWidth: Integer; procedure HandleWordListLostFocus(ASender: TObject); procedure HandleWordListSelectItem(ASender: TObject); procedure HandleWordListKeyPress(Sender: TObject; var Key: Char); procedure HandleWordListKeyDown(ASender: TObject; var Key: Word; Shift: TShiftState); procedure HandleHideWordList(var AMsg); overload; message MSG_HIDEWORDLIST; procedure HandleHideWordList; overload; procedure SetWordListHeight(const Value: Integer); procedure SetWordListWidth(const Value: Integer); procedure RegainFocus; protected procedure ShowWordList(AWords: TStrings); procedure HideWordList; procedure Change; override; procedure KeyDown(var Key: Word; Shift: TShiftState); override; procedure DoExit; override; public constructor Create(AOwner: TComponent); override; published property WordListHeight: Integer read FWordListHeight write SetWordListHeight; property WordListWidth: Integer read FWordListWidth write SetWordListWidth; end; TAutocompleteMan=class private FWords: TStrings; public constructor Create; destructor Destroy; override; function IsRecognized(AWord: string): Boolean; overload; function IsRecognized(AWord: string; AWordList: TStrings): Boolean; overload; procedure LoadFromFile(const AFilename: string); procedure AddWord(const AWord: string); property Words: TStrings read FWords; end; procedure Register; var AutocompleteMan: TAutocompleteMan; implementation procedure Register; begin RegisterComponents('CodeCall', [TAutocompleteEdit]); end; { TAutocompleteMan } procedure TAutocompleteMan.AddWord(const AWord: string); begin FWords.Add(UpperCase(AWord) + '=' + AWord); end; constructor TAutocompleteMan.Create; begin FWords := TStringList.Create; TStringList(FWords).Duplicates := dupIgnore; end; destructor TAutocompleteMan.Destroy; begin FWords.Free; inherited; end; function TAutocompleteMan.IsRecognized(AWord: string): Boolean; var i: Integer; begin Result := False; AWord := UpperCase(AWord); for i := 0 to FWords.Count-1 do begin Result := System.Pos(AWord, FWords.Names) > 0; if Result then Break; end; end; function TAutocompleteMan.IsRecognized(AWord: string; AWordList: TStrings): Boolean; var i: Integer; begin Result := False; AWord := UpperCase(AWord); AWordList.Clear; for i := 0 to FWords.Count-1 do begin if System.Pos(AWord, FWords.Names) > 0 then begin Result := True; AWordList.Add(FWords.ValueFromIndex); end; end; end; procedure TAutocompleteMan.LoadFromFile(const AFilename: string); var i: Integer; F: TStrings; begin F := TStringList.Create; try F.LoadFromFile(AFilename); for i := 0 to F.Count-1 do AddWord(F); finally F.Free; end; end; { TAutocompleteEdit } procedure TAutocompleteEdit.Change; var S: TStrings; begin inherited; if AutocompleteMan.IsRecognized(Self.Text) then begin S := TStringList.Create; try if AutocompleteMan.IsRecognized(Self.Text, S) then ShowWordList(S); finally S.Free; end; end else HideWordList; end; procedure TAutocompleteEdit.HandleHideWordList(var AMsg); begin HandleHideWordList; end; constructor TAutocompleteEdit.Create(AOwner: TComponent); begin inherited; FWordListHeight := 60; end; procedure TAutocompleteEdit.DoExit; begin if Assigned(FWordList) and FWordList.Visible and not FWordList.Focused then HideWordList; inherited; end; procedure TAutocompleteEdit.HandleHideWordList; begin FWordList.Free; FWordList := nil; end; procedure TAutocompleteEdit.HandleWordListKeyDown(ASender: TObject; var Key: Word; Shift: TShiftState); begin if (Key=VK_UP) and (FWordList.ItemIndex=0) then RegainFocus; end; procedure TAutocompleteEdit.HandleWordListKeyPress(Sender: TObject; var Key: Char); begin case Key of #13: begin Key := #0; Self.Text := FWordList.Items[FWordList.ItemIndex]; Self.SetFocus; Self.SelStart := Length(Self.Text); Self.SelLength := 0; HideWordList; end; #27: begin RegainFocus; HideWordList; end; else begin RegainFocus; end; end; end; procedure TAutocompleteEdit.HandleWordListLostFocus(ASender: TObject); begin if not Self.Focused then HideWordList; end; procedure TAutocompleteEdit.HandleWordListSelectItem(ASender: TObject); begin Self.Text := FWordList.Items[FWordList.ItemIndex]; HideWordList; end; procedure TAutocompleteEdit.HideWordList; begin PostMessage(Self.Handle, MSG_HIDEWORDLIST, 0, 0); end; procedure TAutocompleteEdit.KeyDown(var Key: Word; Shift: TShiftState); begin if Key=VK_ESCAPE then HideWordList else if (Key=VK_DOWN) and Assigned(FWordList) and FWordList.Visible then begin FCaretPos := Self.SelStart; FWordList.SetFocus; if FWordList.ItemIndex < 0 then FWordList.ItemIndex := 0; end else inherited; end; procedure TAutocompleteEdit.RegainFocus; begin Self.SetFocus; Self.SelStart := FCaretPos; Self.SelLength := 0; end; procedure TAutocompleteEdit.SetWordListHeight(const Value: Integer); begin if FWordListHeight <> Value then begin FWordListHeight := Value; if Assigned(FWordList) then FWordList.Height := FWordListHeight; end; end; procedure TAutocompleteEdit.SetWordListWidth(const Value: Integer); begin if FWordListWidth <> Value then begin FWordListWidth := Value; if Assigned(FWordList) then begin if FWordListWidth < 1 then FWordList.Width := Self.Width else FWordList.Width := FWordListWidth; end; end; end; procedure TAutocompleteEdit.ShowWordList(AWords: TStrings); begin if FWordList=nil then begin FWordList := TListBox.Create(Self); FWordList.ParentCtl3D := False; FWordList.Ctl3D := False; FWordList.Parent := Self.Parent; FWordList.TabStop := False; FWordList.OnExit := HandleWordListLostFocus; FWordList.OnKeyPress := HandleWordListKeyPress; FWordList.OnKeyDown := HandleWordListKeyDown; end; FWordList.Items.Assign(AWords); if FWordListWidth < 1 then FWordList.SetBounds(Self.Left, Self.Top + Self.Height, Self.Width, FWordListHeight) else FWordList.SetBounds(Self.Left, Self.Top + Self.Height, FWordListWidth, FWordListHeight); FWordList.Show; end; initialization AutocompleteMan := TAutocompleteMan.Create; finalization AutocompleteMan.Free; end.
  18. вот мой код VCL procedure TfmUserEdit.UniFormAjaxEvent(Sender: TComponent; EventName: string; Params: TUniStrings); begin inherited; if self.AlignmentControl = uniAlignmentClient then begin if EventName = constFormResize then begin fWidth := Params.Values['width'].ToInteger; fHeight := Params.Values['height'].ToInteger; end; if EventName = constWindowMove then begin fTop := Params.Values['top'].ToInteger; fLeft := Params.Values['left'].ToInteger; end; end; end; procedure TfmUserEdit.UniFormClose(Sender: TObject; var Action: TCloseAction); begin self.Left := fLeft; self.Top := fTop; self.Width := fWidth; self.Height := fHeight; inherited;// сохранить параметры в базу при закрытии end; procedure TfmUserEdit.UniFormShow(Sender: TObject); begin inherited;// восстановить размеры // записать в переменные размеры по умолчанию fLeft := self.Left; fTop := self.Top; fWidth := self.Width; fHeight := self.Height; end; JS function window.move(sender, x, y, eOpts) { ajaxRequest(sender, "WindowMove", ['left=' + x, 'top=' + y]); } function form.resize(sender, width, height, oldWidth, oldHeight, eOpts) { ajaxRequest(sender, "FormResize", ['width=' + width, 'height=' + height]); }
  19. Hi, I need to use in de same application for more than one SSL certificate. How I do that? UNIGUI 1.50.0.1480 Delphi 10.2 Thanks!
  20. When I set the title on the login screen, after retrieving the user, it works fine, but there are users who have automatic login, passing a hash by the URL as a parameter, this case does not work procedure TUniMainModule.UniGUIMainModuleBeforeLogin(Sender: TObject; var Handled: Boolean); var aApp: TUniGUIApplication; lCliente: String; begin Handled := False; aApp := (Sender as TUniGUISession).UniApplication; lCliente := aApp.Parameters.Values['u']; if not lCliente.IsEmpty then begin var lClientAuth := Self.ClientApiAuth; try try Self.TOKEN_API := lClientAuth.Service<IServiceLogin>.ValidaLoginHash(UpperCase(lCliente)); Handled := (Self.TOKEN_API <> ''); if Handled then begin UniMainModule.SetUserLogado(Self.GetClientApiApp.Service<IServiceUsuario>.FindUsuarioByHash(UpperCase(lCliente))); if Self.UserActive.Empresa <> nil then Self.Title := 'Assistência 24 HS - ' + UniMainModule.UserActive.Empresa.NomeFantasia; UniSession.UserString := UniMainModule.UserActive.Nome + ' - Mobile'; end; except Handled := False; end; finally lClientAuth.Free; end; end; end;
  21. There is the possibility of selecting the certificate model A3? Another question is if you would like to list the A1 certificates of the access computer and not the server ... Would that be possible?
  22. I have a sign software, with that I can open a pdf file and sign my name in the pdf file(the first image), but,when I open the signed pdf file with UniPDFFrame, I can only see the pdf file's original context (the second image), but can not see the signature(the first image), what's wrong with UniPDFFrame?
  23. Farshad Mohajeri

    SSL

    Hi, This issue occurs in Chrome. The SSL demo uses a self-signed certificate. That's the reason. Chrome doesn't like self-signed certificates. You can ignore this error or run the app in non-debug mode.
  24. procedure TUniCheckComboBoxObject._RemoteQuery(const QueryString: string; Result: TStrings); begin Self.SearchData(QueryString); Result.Clear; while not Self.FTable.Eof do begin var lStrListValue := Self.GetValueProp(Self.FTable); if not lStrListValue.IsEmpty then Result.AddObject(lStrListValue, Self.FTable.Current<TObject>); Self.FTable.Next; end; end; I'm modifying this component, almost everything works, I have the following problem, when selecting the items it does not trigger the internal selection function in the component when running this line here FSelList[I] := FOwner.uItems.StringFromId(Ix); (uniComboBox line 1465) is always empty. The AfterNotifyAjax function is not firing UniCheckComboBoxObject.pas
  25. Hello, I have this event on ExtEvents function click(sender, e, eOpts) { MyForm.window.showMask(); ajaxRequest(MyForm.window, 'newemail',[]); } due to creating multiple forms on runtime, the MyForm got multiple names such as Myform, MyForm_1, which lead to error on JS on running the application. On delphi code I can give self.name + '.window.hidemask(), but how can I call self.name from javascript code?
×
×
  • Create New...