Sitcky based on HTTP Strings
Hello Experts!
I'm working with a CSS 11503, software version 7.40.
An issue has arised when trying to load balance web services running on Novell Application servers.
Usign Cookies to achive sticky (which works pretty fine), we have face an odd behaviour on Novell Servers. Cookie server string changes on every server start up, so every time the servers are restarted, we need to reconfigure "string" command.
We have open a ticket with Novell to see how this can be fixed. In the meanwhile (they are no as faster as Cisco support ;-) I was wondering about the posibility of making sticky dependent on an HTTP string (that's something we can configure on the applicantion server).
Does anybody know if this is possible for the CSS?
Thanks for your replies and best regards!
yes, it is possible.
http://www.cisco.com/en/US/products/hw/contnetw/ps792/products_configuration_guide_chapter09186a0080117629.html#23158
"advanced-balance url - Enables the content rule to stick a client to a server based on a configured string found in the URL of the HTTP request. You must specify a port in the content rule to use this option. The CSS will then spoof the connection."
http://www.cisco.com/en/US/products/hw/contnetw/ps792/products_configuration_guide_chapter09186a00802928db.html#wp1115519
If you need anything else, let us know.
Thanks,
Gilles.
Similar Messages
-
Split text file in multiple files based on a string
Hey all,
I want to split a text file into multiple files. I already found some examples where there is a split based on a number of files.
http://forum.java.sun.com/thread.jspa?forumID=256&threadID=260930
But I want to make a split based on a string (word) that I find in the file.
Anyone that can help me ?
Regards,
AtmozThis is my testing code like it is now. Maybe there is a bug in there which causes a memory leak or so.
public class test {
public static void main(String args[]) {
File sSourceDir = new File("D:\\Test\\");
File sDestinationDir = new File("D:\\Test\\");
File[] files = sSourceDir.listFiles(new Filter());
for (int i=0; i<files.length; i++) {
File file = files;
if (file.isFile()) {
System.out.println("Splitting file: "+files[i]);
splitFile(file,sDestinationDir);
else {
System.out.println("Not a file: "+files[i]);
public static File splitFile(File fSourceFile, File sDestinationDir) {
int counter = 1;
File fDestinationFile=new File(sDestinationDir,"NEW_"+counter+"_"+fSourceFile.getName());
fDestinationFile.delete();
String sLineOfData=null;
boolean firstfile = true;
try {
BufferedReader DataFileReader = new BufferedReader(new FileReader(fSourceFile));
PrintWriter outputStream = new PrintWriter(new FileWriter(fDestinationFile));
while ((sLineOfData = DataFileReader.readLine()) != null){
System.out.println(sLineOfData);
if (sLineOfData.indexOf("UNA:+") != -1) {
if (!firstfile) {
counter++;
fDestinationFile=new File(sDestinationDir,"NEW_"+counter+"_"+fSourceFile.getName());
outputStream.close();
outputStream = new PrintWriter(new FileWriter(fDestinationFile));
outputStream.println(sLineOfData);
else {
firstfile = false;
outputStream.println(sLineOfData);
else {
outputStream.println(sLineOfData);
outputStream.close();
DataFileReader.close();
} catch (FileNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
return fSourceFile;
And this is an example of a file:
PS: I cut out each long line (that line from 4000 chars)
UNA:+,? '
UNB+UNOC:3d+5499757493404:14+3014331700208:14+050114:1200+ACC302++STS.GZ++1++1'
UNH+I15185477+UTILTS:D:03B:UN:E5BE03'BGM+E32::260+I15185477+9+NA'
DTM+137:200501141151:203'DTM+735:?+0100:406'MKS+23'NAD+MR+3014331700208::9'
UNA:+,? '
UNB+UNOC:3+549975f7493404:14+3014331700208:14+050114:1200+ACC302++STS.GZ++1++1'
UNH+I15185477+UTILTS:D:03B:UN:E5BE03'BGM+E32::260+I15185477+9+NA'
DTM+137:200501141151:203'DTM+735:?+0100:406'MKS+23'NAD+MR+3014331700208::9'
DTM+137:200501141151:203'DTM+735:?+0100:406'MKS+23'NAD+MR+3014331700208::8'
UNA:+,? '
UNB+UNOC:3g+5499757g493404:14+3014331700208:14+050114:1200+ACC302++STS.GZ++1++1'
UNH+I15185477+UTILTS:D:03B:UN:E5BE03'BGM+E32::260+I15185477+9+NA'
DTM+137:200501141151:203'DTM+735:?+0100:406'MKS+23'NAD+MR+3014331700208::9'Message was edited by:
Atmozzz -
Form based authentication HTTP 403 access forbidden in WL 8.1
Hi there..
I found following message posted in April-2004 by Sandeep very useful.
I also ended up getting the following HTTP 403 Forbidden access error while using Pageflow controller and Form based authentication.
I noticed 2 things. If you have a normal webapp A, which is a plain old webapp (which does not use pageflow..workshop etc..) then the following error does not occur.
It only happens with those webapps which utilizes WL 8.1's pageflow features. Note that I am not using nested page flows. I just used 1 pageflow controller and wanted to have the form based login feature for the same.
BEA's samples on form authentication talks about nested page flows and javax.security.auth.login.FailedLoginException and etc.. are they only applicable to nested pageflows?
can't I use the same to capture failed login exception within a single controller?
I tried out putting FailedLoginException exception-handler in Global.app file but it didn't catch it. Only the following work around worked. is this a bug in WL 8.1 workshop? or I am missing something.
I would appreciate if someone can clear this doubt.
I am using WL 8.1 with sp3.
Rajesh
Hey guys,
I could find the solution for my problem. Here it is
We need to add following lines of code in the erro.jsp page.
<form action"j_security_check>
....write the error mesage....
</form>
You will get rid of "403 Forbidden page" error.
Thanks,
Sandip
[email protected] (Sandip Atkole) wrote in message news:<[email protected]>...
I am trying to set up Form-Based Authentication on WebLogic 8.1
The Problem:
If the user provides correct userid/password, he gets access to the
protected resource as required, but if he provides incorrect
userid/password, he gets a 403 Forbidden page, instead of getting the
login failure page.
The Descriptors:
WEB.XML
<login-config>
<auth-method>FORM</auth-method>
<form-login-config>
<form-login-page>/Login.jsp</form-login-page>
<form-error-page>/LoginError.jsp</form-error-page>
</form-login-config>
</login-config>
Why doesn't it redirect to "/LoginError.jsp" instead of showing the
403 Forbidden page?
Thanks in advance
SandipIt seems like a bug. However when I explicitly reset the error using set status it worked for me. I added following code in my error jsp .
<%
response.setHeader("conent-type","text/html");
response.setStatus(200);
%> -
URL object with https string throws malformed url exception: unknown protocol: https
In WebLogic I am trying to connect to an HTTPS url by passing that url
string into the contructor for URL object. This throws a Malformed URL
Exception : unknown protocol: https.
When i run this same block of code outside of weblogic (in a stand-alone
app), it runs perfectly. (not exceptions when creating the URL object).
why do i get this exception in weblogic?
could weblogic be loading its own URL class rather than the java.net.URL
class (which supports ssl)? if so how do i override that classloading?
is there a weblogic security "feature" that prevents opening an ssl
connection?
thanks for any help
mike
[email protected]You need to modify your weblogic.policy file to allow you to change the
the property java.protocol.handler.pkgs ... and any other properties
that you may probably change using JSSE (for example:
javax.net.ssl.trustStore for storing certificates of servers that you
want to connect to from WLS )
Regards,
John Salvo
Michael Harrison wrote:
>
thanks for the help dennis, but still get the "unknown protocol https".
the URL object sees that the URLStreamHandler ==null and get the value for
java.protocol.handler.pkgs (which should be
com.sun.net.ssl.internal.www.protocol) then it tries to load that class. i
believe that the GetPropertyAction("java.protocol.handler.pkgs","") is not
returning com.sun.net.ssl.internal.www.protocol. therefore the class is not
getting loaded
i think that my classpath is set up properly for classpath and
weblogic_classpath so i think that i me calling
System.setProperty("java.protocol.handler.pkgs",
"com.sun.net.ssl.internal.www.protocol"); is not effective.
do you know anyway i can trouble shoot this.
thanks
mike
Dennis O'Neill <[email protected]> wrote in message
news:39d23c28$[email protected]..
Https is an add-in so to speak. Try this before you create your url:
System.setProperty ("java.protocol.handler.pkgs",
"com.sun.net.ssl.internal.www.protocol");
// add the default security provider (again, in JSSE1.0.1)
int iap = java.security.Security.addProvider(new
com.sun.net.ssl.internal.ssl.Provider() );
dennis -
IBNS web-based authentication HTTPS intercept
Hi everybody,
Hopefully this is an easy question.
I have configured an IBNS setup with Wired Web-Authentication. To sum this up: connect a computer to the switch, go to a web page, the switch intercepts the http request, sends you a log-in page, you log in and get directed to the original web page.
For this, I have used the following guide http://www.cisco.com/en/US/prod/collateral/iosswrel/ps6537/ps6586/ps6638/app_note_c27-577494.html
Before I implemented this, I had the HTTP and HTTPS server on the switch disabled. But if I disable the HTTP serer (and leave the HTTPS server enabled), the switch doesn't intercept the web pages anymore. Is there a way to use web-based authentication without using the HTTP server and using only the HTTPS server on the switch?
Hope someone can help me with this.
Thanks
IanWell I haven't had any luck getting an iPhone to present an SSL certificate to an IIS7 ASP.Net webserver.
The same .p12 certificate works on IE7, PocketIE (WM6), Firefox and Safari (PC version). The website is set to Require an SSL certificate. From the Windows Mobile or PC browsers, you get a prompt for the client certificate. I have tried Nick's website and the iPhone will prompt to choose between his and my certificates, however with IIS7 you just get a 403.7 client SSL certificate required error.
I have turned on SSL tracing in HTTP.Sys and get the following (edited for length) :
<Opcode>SslInititateSslRcvClientCert</Opcode>
- <Keywords>
<Keyword>Flagged on all HTTP events handling ssl interactions</Keyword>
</Keywords>
<Task>HTTP SSL Trace Task</Task>
<Message>Server application is attempting to receive the SSL client certificate, which will be provided if available. If the client certificate is not available, a renegotiation will be initiated.</Message>
<Channel>HTTP Service Channel</Channel>
<Provider>Microsoft-Windows-HttpService</Provider>
... then after various SSL negotiations and receive raw data traces I see...
<Opcode>SslRcvClientCertFailed</Opcode>
- <Keywords>
<Keyword>Flagged on all HTTP events handling ssl interactions</Keyword>
</Keywords>
<Task>HTTP SSL Trace Task</Task>
<Message>Attempt by server application to receive client certificate failed with status: 0xC0000225.</Message>
<Channel>HTTP Service Channel</Channel>
<Provider>Microsoft-Windows-HttpService</Provider>
Which basically seems to mean a "not found" error.
Anyone had any luck with iPhone to IIS 7 (which we have to use as it is an ASP.Net website)? -
Is there a way to direct requests based on HTTP return-code checking?
I'd like to implement a policy based on return-code. The algorithm is as below,
If HTTP return-code == 500 to 600
serverfarm1
else
serverfarm2
We have a CSM V3.2. Can someone tell me if this is doable? If yes, would you please tell me how.
Appreciation, Q.XieThe solution I suggested is still what I recommend.
What you have to do is split your serverfarm in multiples instances. One for HTTP and another one for the rest of your applications. Or you could do one for each application.
The serverfarm for HTTP will have the HTTP probe and will go down when the response is 500-600.
The other serverfarm(s) will not use the same HTTP probe and should not go down based on the response code.
ie:
serverfarm WEB
real 10.10.10.10
ins
real 20.20.20.20
ins
probe http
serverm ALL
real 10.10.10.10
ins
real 20.20.20.20
ins
no probe
vserver web
vip 1.1.1.1 tcp 80
serverfarm WEB backup WEB_B
vserver all
vip 1.1.1.1 any
serverfarm ALL
Hope this helps.
Gilles.
Thanks for rating this answer. -
Can the ACE bleed off users based on http probe?
We need to have our ACE look at our two servers, and based on the text it sees on a predetermined page, take an action.
Example 1: ACE looks at web page on server1, and sees "maintenance". Desired action - send all users to server2, & wait for server1 to bleed off all users.
Example 2: ACE looks at web page on server1, and sees "online". Desired action - allow users to go back to server1.
current config:
probe http HTTP-Server1
interval 15
passdetect interval 2
request method get url /maintenance.htm
expect status 200 200
probe http HTTP-Server2
interval 15
passdetect interval 2
request method get url /maintenance.htm
expect status 200 200
Thanks.if you are looking at content for maintenance and online you need to do 2 things
1. make sure server uses content length header in reply to probe
2. construct probe to look for content as the criteria for probe success or failure so probe would be:
probe http HTTP-Server1
interval 15
passdetect interval 2
request method get url /maintenance.htm
expect regex "online"
if content does not have online probe will fail new connections would go to other server existing connections will be maintained.
Regards -
How to get these substrings based on the string entered
Hi friends
i want the substring entered in the string
the string is something like this: 1234,3653,7684,3254,8777,987,234
now i want
the substrings between commas
can some one help me with it pls
in the first substring i need 1234
in the second i need 3653...
so on till the end..
what ever the string be until the last one
pls helpHi,
You can do something like this:
SELECT txt
, REGEXP_SUBSTR (txt, '[^,]+', 1, 1) AS part_1
, REGEXP_SUBSTR (txt, '[^,]+', 1, 2) AS part_2
, REGEXP_SUBSTR (txt, '[^,]+', 1, 3) AS part_3
FROM table_x
;If there are fewer than n parts, then the technique above will not raise an error; it will just return NULL for part_n.
I hope this answers your question.
If not, post a little sample data (CREATE TABLE and INSERT statements, relevant columns only), and the results you want from that data.
Explain how you get those results from that data.
What do you want if the input is like this"
{code}
'foo,,bar'
{code}
? Do you want to consider this as 2 parts ('bar' is the 2nd) or a s 3 (the 2nd is NULL, and 'bar' is the 3rd)? Include examples in your sample data and results.
Always say what version of Oracle you're using. -
How to use BPEL to integrate ASP scripts based on https authentication???
Hello,
We are trying to use BPEL to integrate with a third party tool. The information available is:
1. URL https://***/***/***.asp
2. parameter name "request"
3. post XML request
Can we achieve it using BPEL parterlink? If we can, can you help give some pointers how to do it?
Thanks a lot!
WenSome general information on configure message-level security can be found here: http://download.oracle.com/docs/cd/E14571_01/web.1111/e13713/message.htm#g352961
and http://download.oracle.com/docs/cd/E17904_01/web.1111/e13713/toc.htm
Note that WebLogic ships with a number of policy files that can be found here: http://download.oracle.com/docs/cd/E14571_01/web.1111/e13713/message.htm#i244059
The basic steps are outlined here: http://download.oracle.com/docs/cd/E14571_01/web.1111/e13713/message.htm#i210119 -
Using OWSM to secure Services based on http binding
Hi,
We are using OWSM Gateway in DMZ as a proxy server to communicate with systems beyond the firewall. We have two specific requirements:
1) The BPEL/ESB services should invoke http POST/GET services on the third party systems which are located beyond the firewall.
2) Third party services uses http POST/GET to access the BPEL/ESB services.
My queries are:
Are these possible with OWSM?
For reqmnt 1, when we tried with OWSM we are getting the following error
"No policies found for service "SID0003001/servletclasstest?Locality=Chennai.Make sure the service is registered correctly and gateway policies are up to date"
Can any one help us out with solution. We are running on tight timelines any help is highly appreciatedHave you resolved your issue. I am in the same situation. Can you please let me know how you have resolved your issue.
-
How to determine a component length based on a string length?
for example:
int strLength = aString.length();
if strLength = 20,then when aString displays in a label,
what is the label's length?getJLabel().getText().length()If you want to get the size of the component, it's another topic.
-
ACE for sql injection filtering
I have an ACE module in a Cat6500, that is load balancing to some HTTP servers.
occasionally there are SQL injection attacks towards the http servers.
I know the ACE can filter based on http strings, but
If you can provide me with some basic templates on what to filter out and how to format the string
to stop SQL injection attacks, that would be of great help.
Cheers.There are various signatures which are availbale for configuration for sql injection attacks. The signatures are some times application specific and it may not fit other application. Following links may help you
http://www.cisco.com/en/US/products/ps7314/products_white_paper0900aecd8068dcdb.shtml
http://www.cisco.com/en/US/products/ps7314/products_white_paper0900aecd80661ca6.shtml -
How to extract substring from a string based on the condition ??
Hi,
I'm having a very large string which as below
EQD+CN+SAMPLE18767+2200+++5'
NAD+CA+FIR:172:20'
DGS+IMD+3.2+2346+55:CEL'
FTX+AAA+++GOOD'
FTX+AAA+++ONE'
EQD+CN+SAMPLE18795+2200+++5'
NAD+CA+TIR:172:20'
DGS+IMD+3.2+2346+55:CEL'
FTX+AAA+++SECOND'
FTX+AAA+++IS FAIR'
similarly FTX+AAA as above and it goes on
i tokenized each segment with delimiter as ' and able to read each segment.
Now i want to concatenate the FTX+AAA in a single segment if more than one FTX+AAA with IMMEDIATE below
The output is as follows
EQD+CN+SAMPLE18767+2200+++5'
NAD+CA+FIR:172:20'
DGS+IMD+3.2+2346+55:CEL'
FTX+AAA+++GOOD,ONE'
EQD+CN+SAMPLE18795+2200+++5'
NAD+CA+TIR:172:20'
DGS+IMD+3.2+2346+55:CEL'
FTX+AAA+++SECOND,IS FAIR'
similarly FTX+AAA should be concatenated if it has similar FTX+AAA IMMEDIATE below.
The FTX+AAA segments can come any number of times immediate below
Please help me how we can do this??? Can anyone help me with the code snippet to do this?
Thanks,
KathirEncephalopathic wrote:
You've posted > 300 times here and you still don't respect the rule regarding notification of all cross-posts? [http://www.java-forums.org/advanced-java/30061-how-extract-substring-string-based-condition.html]
Do you think this this will help convince others to help you?See also [http://www.coderanch.com/t/500088/java/java/extract-substring-string-based-condition|http://www.coderanch.com/t/500088/java/java/extract-substring-string-based-condition]. -
CSS Troubleshooting "advanced-balance url" based on string-range
Hi together,
a questions for troubleshooting "string range stickyness".
I configured a content rule:
content L5_HTTP_81
vip address 192.168.1.1
balance aca
no persistent
protocol tcp
port 81
url "/*"
advanced-balance url
add service service1 weight 1
add service service2 weight 1
string range 30 to 255
string eos-char "_"
string prefix "shopId="
active
service service1
ip address 10.1.128.23
keepalive maxfailure 2
protocol tcp
redundant-index 2102
keepalive frequency 15
keepalive retryperiod 10
keepalive type http
keepalive port 80
keepalive method get
keepalive uri "/admin/Ping.simple"
string 148.49
port 80
active
service service2
ip address 10.1.128.22
keepalive maxfailure 2
protocol tcp
redundant-index 2101
keepalive type http
keepalive method get
keepalive frequency 15
keepalive retryperiod 10
keepalive port 80
keepalive uri "/admin/Ping.simple"
string 148.48
port 80
active
1. I take a string from the 30rd to 255 character out of the URL starting at "/".
2. Now I search for a string between "shop_Id=" and "_", on which the stickyness is based.
3. string "148.49" is allocated to service1, string "148.48" is allocated to service2.
Is there any possibillity to view or debug the handling, how the string is matched in the http request and on which service the request is forwarded ?
thanks in advance
saschaHere is the command reference. take a look at the available commands.
http://www.cisco.com/univercd/cc/td/doc/product/webscale/css/css_710/cmdrefgd/index.htm -
Java Program to run an https based url
This is the simple code to read through a java program from a simple http based procot URL
import java.net.*;
import java.io.*;
public class URLReader {
public static void main(String[] args) throws Exception {
URL yahoo = new URL("http://mail.yahoo.com/");
BufferedReader in = new BufferedReader(
new InputStreamReader(
yahoo.openStream()));
String inputLine;
while ((inputLine = in.readLine()) != null)
System.out.println(inputLine);
in.close();
But if i use the url https://mail.yahoo.com/ instead of http://mail.yahoo.com/ then i have an exception given below
Exception in thread "main" java.io.IOException: HTTPS hostname wrong: should be
<mail.yahoo.com>
at sun.net.www.protocol.https.HttpsClient.b(DashoA12275)
at sun.net.www.protocol.https.HttpsClient.afterConnect(DashoA12275)
at sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect
(DashoA12275)
at sun.net.www.protocol.http.HttpURLConnection.getInputStream(HttpURLCon
nection.java:626)
at sun.net.www.protocol.https.HttpsURLConnectionImpl.getInputStream(Dash
oA12275)
at java.net.URL.openStream(URL.java:913)
at URLReader.main(URLReader.java:7)
Now i want this program based on https to run. SO can anybody help me running the same program by using https? Or can anybody give me the code to run a url based on https protocol?Same as http://forum.java.sun.com/thread.jspa?threadID=677398&tstart=0 . Check reply on the other post.
Maybe you are looking for
-
Memory upgrade on Satellite 2410
Hi. I have a Satellite 2410-703 and i'd like to upgrade my ram to 1024. Now there are two SoDimm 256Mb@266Mhz (Pc2100). My question is: may I use other Kingston module at 333 or 400 Mhz? Are they compatible? Thanks a lot. Antonio
-
is it possible to downland itunes 10.6.3 I have an old Macbook pro with OSX 10.5.8 and lost my itunes and cannot seem to download a version compatible with the computer?
-
My Wishlist for WebOs Update 1.4.5 - ALL REASONABLE AND Somewhat EASY.
I just bought a Palm Pre and I love it far more than any windows or blackberry phone I ever had and far more than my old iphone. Its also, in my opinion, more of a draw for me than the android is. And I am sure that even though I am posting this, man
-
Need Help setting up a Fully-Accessible External Harddrive on Network.
Alright Ladies and Gentlmen of the Apple Support Forums, I'm fairly new to servers in general - but I thought I'd be able to figure this one out on my own...I guess I was wrong I am the tech head of a video studio that needs to share a single 12 TB e
-
Strange publishing error in captivate 5. Help!
http://img837.imageshack.us/img837/4295/captivateerrorimage.jpg I created a project in captivate 5 and then published an .exe of it, now I am able to view that exe file on my pc but when I try to open the same file on other pc, its giving me the abov