Article
· Dec 12, 2016 3m read
Generate and Validate Captcha Code

Suppose you have developed your own web app with InterSystems technologies stack and now want to perform a captcha validation on the client side in order to determine whether or not the user is human and make it safer. There are some modern frameworks to address the captcha issue, however most part of them needs internet access to generate codes and sometimes are complex to implement. Take this as basic example considering that image recognition has gotten too good. That's why you nowadays you tend to see more pattern recognition captchas than mere reading ones. (I.e.

7 9
2 1.4K
Article
· Oct 7, 2016 4m read
Forwarding Requests in a REST Service

One useful feature of our REST framework is the ability for a dispatch class to identify request prefixes and forward them to another dispatch class. This approach of modularizing your URL map will improve code readability, enable you to easily maintain separate versions of an interface, and provide a means to protect API calls that only certain users will be allowed to access.

7 1
0 3.6K

Hi!

I am not system admin. But it used to be very simple to install CSP Gateway on an apache system on Linux with Apache installed. I used to run the CSP Gateway installation program and after it was done, all I had to do was fine tune some configurations on CSP Gateway portal on http://<ip>/csp/bin/Systems/Module.cxw and I was up and running.

0 5
0 1.3K

Hi all,
Basically i have 2 queries..

  1. Is there any simple way to fetch the data directly from the database (using the URL and credentials) from the csp file without creating a link table for that particular Table...??
    If there is, could you please share the syntax of using them ..?

  2. Can we have an object return type from the below mentioned method to a javascript function.. ???

0 9
0 737

Hi all,

We've found that in most cases when we open a new CSP session the CGI varaiable %CGIEVAR("HTTP_COOKIE") contains the client name.

It looks like that : "state=SYSADM%3A0; Username=Urish; CSPWSERVERID=Cache for Windows (x86-64) 2013.1.1 (Build 501_1_13062) Sun Aug 11..."
In some other cases this CGI only contains $zv - like "CSPWSERVERID=Cache for Windows (x86-64) 2013.1.1 (Build 501_1_13062) Sun Aug 11 2013 23:20:33 EDT"

0 2
0 410

Hi,

I am using the &sql () tag to retrieve the value from the Cache DB.

below is the piece of code i am using:

script language="cache" method="retrieveDetail" arguments="pVariable" returntype="%String"
&sql( select columnA,
into :tempVariable1
from TABLE
where COLUMNC = pVariable

quit tempVariable1

i have to return the ColumnA value back to the calling procedure.

can i know how it can be done ? since i am getting an javascript error.

1 4
0 367

Interesting anecdote I want to share. Not 100% Caché related, but I hope it would be useful.

When CSP Gateway is configured on IIS, opening CSP Gateway Configuration page is prohibited by default -- as IIS blocks URLs with '/bin' in it.

In our documentation we advise to add <remove segment="bin" /> to applicationHost.config file.
That is correct.

4 0
0 881

Hi


I have been working on changing a web application from using %FileBinaryStream to storing and serving the file content from a %Stream.GlobalBinary property, stored in a new database. I have managed to migrate the data across, and have also been able to redirect the stream so that it is being served through the web link. However, the previous method set attributes on the File stream to have the stream be rendered as the original file type through MIME, using this code

0 2
0 943

Hi all,

Do anyone know how to force to close the CSP connection used before redirecting to a different page so a new connection ( and therefore a new session id) is generated?

The idea is to generate new CSP session once we log off our application so the session identifiers are different.

Best Regards

1 4
0 495

I've noticed that Management portal somehow manages to allow a single user to be in different namespaces in different tabs in the same application (i.e. Management Portal). I've looked at my Processes, however, and see that all of my processes using MgmtPortal think I'm in %SYS, even though 2 of them are looking at globals in two different namespaces; NamespaceA and NamespaceB.

I can even fool MgmtPortal because the first time I try to look at a global in NamespaceA it thinks I'm in %SYS! After a refresh, however, I can see the global in NamespaceA.

0 8
0 642
Question
· Aug 22, 2016
$fromJSON and MAXSTRING

Hi, all.
I have CSP application and it needs to get and process data from ajax request with json-content. JSON can be very big.
In this case:
TRY
{
Set RequestObj = ##class(%Object).$fromJSON(%request.Content.Read())
} CATCH(Exception) {
Set Status=Exception.AsStatus()
}
I get just part of getting JSON and validate error in $fromJSON.
If I try to read it all in cycle:
TRY
{
While (%request.Content.AtEnd = 0) {

0 6
0 1.4K

在Aix7.1上安装使用root用户安装cache2016.1.1.107,且在安装过程中创建cacheusr用户;更改操作系统上的cacheusr的umask后,通过数据库修改编译后的文件(如,js,csp等)在小机上查看权限不变(-rwxrw-r-- cacheusr cacheusr test.js)。

目的:通过数据库编译后的文件的other用户有读写权限。

5 3
0 923