Hello,

I succeeded with a proxy_pass on a front ngnix server by transforming :

https://www.domain.tld/ape/frequency/request  to 
https://frequency.ape.ourapeserver.tld/2/request


On Ngnix Server :
    location ~*^\/ape\/(\d+)\/$ {
            proxy_pass https://$1.ape.domain.tld:443/2$request_uri;
    }


On JSF Framework (Source/Core/Core.js), I replaced :

        this.serverUri = (this.options.secure ? 'https' : 'http') + '://' + 
this.options.frequency + '.' + this.options.server + '/' + 
this.options.transport + '/?',
       
by :

        this.serverUri = (this.options.secure ? 'https' : 'http') + '://' + 
this.options.server + '/ape/' + this.options.frequency + '/?',


If this can help anyone ;)

Have a nice day


Le mardi 11 décembre 2012 16:59:30 UTC+1, Pablo a écrit :
>
> Yes you could, do you see how the chl or challenge is send in every 
> command, you just have to send the frequency value in the json variable 
> freq instead of adding it to the domain.
>
> So a command would look like:
>
> [{cmd: "connect", chl:34, freq:11 ...}]
>
> For example in the APE_JSF framework there is function called parseCmd() 
> which builds the outgoing commad. 
>
>
> https://github.com/APE-Project/APE_JSF/blob/master/Source/Request/Request.js
>
> In line 53 and 83 you could see it adds the challenge # or chl so you 
> would add the frequency below that line
>
> o.freq = the frequency # 
>
> To avoid the frequency to be added to the domain you would have to go in 
> the source and edit every transport. You would be looking for a  line like 
> this.ape.options.frequency 
>
> In case of the websocket is on line 12 on the file 
>
> https://github.com/APE-Project/APE_JSF/blob/master/Source/Transport/Transport.WebSocket.js
>
> If you manage to make this edits work you can tested it on the fork 
> https://github.com/ptejada/APE_Server
>
> But do note that the fork is not ready for prime time as it has a minor 
> bug for the longpolling protocol. The websocket however works flawlesly,
>
> good luck
> On Dec 11, 2012 10:25 AM, "Mathieu Bodjikian" 
> <[email protected]<javascript:>> 
> wrote:
>
>> Thanks, I saw your work but could it be possible to disable wildcard and 
>> keep the existing JSF framework ? 
>>
>> Or just modify one or two lines ? I have a production environement and I 
>> need to modify it as quickly as possible.
>>
>>
>> Thank you for your precious help :)
>>
>>
>> Le mardi 11 décembre 2012 16:06:41 UTC+1, Pablo a écrit :
>>>
>>> Check this commit from a fork i have, it doesn't delete lines but rather 
>>> tries to use a frequency in the json command instead than in the domain.
>>> On Dec 11, 2012 9:51 AM, "Mathieu Bodjikian" <[email protected]> wrote:
>>>
>>>> Hello, can you tell me which file and lines did you modified/delete 
>>>> please ? 
>>>>
>>>> Thanks
>>>>
>>>> Le mardi 8 mai 2012 22:15:41 UTC+2, ofosho a écrit :
>>>>>
>>>>> I have created a small intranet for my company which uses SSL. In 
>>>>> order to get APE running without the need for a wildcard certificate, I 
>>>>> removed the 3 places where frequency is attached to the URL. I found a 
>>>>> few 
>>>>> discussions that say that it is "not possible" to do this, citing 
>>>>> multi-window/tab support. I have found no such issues, and I believe it 
>>>>> is because of how I use ape.
>>>>>
>>>>> I needed a way to send site-wide push notifications of activities in 
>>>>> the system. Basically Alice performs X, and I need a way to inform every 
>>>>> currently logged in user of what just happened. Really it is just an 
>>>>> alert 
>>>>> system, but it seems to work after light testing.
>>>>>
>>>>> My question is, can anyone tell me of a scenario where this wouldn't 
>>>>> work? I feel like there has to be something I am missing. What features 
>>>>> am 
>>>>> I leaving on the table? I don't need to send individual messages, just 
>>>>> broadcasts.
>>>>>
>>>>> Lastly, if there is seemingly no problem with this set up, wouldn't my 
>>>>> use-case apply to more people than just myself? Wouldn't this be 
>>>>> something 
>>>>> to consider adding to the framework? I only changed 3 lines of code.
>>>>>
>>>>> Thank you,
>>>>>
>>>>> -O
>>>>>
>>>>  -- 
>>>> You received this message because you are subscribed to the Google
>>>> Groups "APE Project" group.
>>>> To post to this group, send email to [email protected]
>>>> To unsubscribe from this group, send email to
>>>> ape-project...@**googlegroups.com
>>>> For more options, visit this group at
>>>> http://groups.google.com/**group/ape-project?hl=en<http://groups.google.com/group/ape-project?hl=en>
>>>> ---
>>>> APE Project (Ajax Push Engine)
>>>> Official website : http://www.ape-project.org/
>>>> Git Hub : http://github.com/APE-Project/
>>>>
>>>  -- 
>> You received this message because you are subscribed to the Google
>> Groups "APE Project" group.
>> To post to this group, send email to [email protected]<javascript:>
>> To unsubscribe from this group, send email to
>> [email protected] <javascript:>
>> For more options, visit this group at
>> http://groups.google.com/group/ape-project?hl=en
>> ---
>> APE Project (Ajax Push Engine)
>> Official website : http://www.ape-project.org/
>> Git Hub : http://github.com/APE-Project/
>>
>

-- 
You received this message because you are subscribed to the Google
Groups "APE Project" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/ape-project?hl=en
---
APE Project (Ajax Push Engine)
Official website : http://www.ape-project.org/
Git Hub : http://github.com/APE-Project/

Reply via email to