Key invalid in messgae error (BouncyCastle Encryption)

I am trying to use bouncycastle to encrypt some data but am getting a "key invalid in message" error whenever I run it. My question is: what the hell could this mean? what could i be doing wrong. I get a feeling it's not a code issue, so what could it be?
This is the actual place it falls over at:
CMSEnvelopedData envData = envGenerator.generate( new CMSProcessableByteArray(signed),CMSEnvelopedDataGenerator.DES_EDE3_CBC, 192,"BC" );
Please help. I am officially confused.

I have the same exception but with an other problem. I want to read an encrypted mail.
KeyStore    ks = KeyStore.getInstance("PKCS12", "BC");
            ks.load(new FileInputStream("/coucou.pfx"), "azerty".toCharArray());
            Enumeration e = ks.aliases();
            String      keyAlias = null;
            while (e.hasMoreElements())
                String  alias = (String)e.nextElement();
                if (ks.isKeyEntry(alias))
                    keyAlias = alias;
            X509Certificate cert = (X509Certificate)ks.getCertificate(keyAlias);
            RecipientId     recId = new RecipientId();
            recId.setSerialNumber(cert.getSerialNumber());
            recId.setIssuer(cert.getIssuerX500Principal().getEncoded());
            SMIMEEnveloped       m = new SMIMEEnveloped(msg);
            RecipientInformationStore   recipients = m.getRecipientInfos();
            RecipientInformation        recipient = recipients.get(recId);
            Iterator iterator = recipients.getRecipients().iterator();
            while(iterator.hasNext())
                 RecipientInformation temp = (RecipientInformation)iterator.next();
                 if(temp!=null)
                      recipient = temp;
            MimeBodyPart        res = SMIMEUtil.toMimeBodyPart(recipient.getContent(ks.getKey(keyAlias, null), "BC"));
            System.out.println(res.getContent());The message "Key invalid in message error " appears at the line :
MimeBodyPart        res = SMIMEUtil.toMimeBodyPart(recipient.getContent(ks.getKey(keyAlias, null), "BC"));Please help !

Similar Messages

  • Key Lenght too short error with dbms_crypto.encrypt

    Hi Friends,
    I am getting above mentioned error with dbms_crypto.encrypt.
    I had created a thread in technology --> security forum but i am not getting any help from there.
    ORA-28234 Key Length too short with dbms_crypto.encrypt
    Appreciate if anyone help me resolve this issue.
    Thanks
    AT

    Hi Warren,
    Yes function is compiled without any compilation error.
    Thanks
    AT

  • Error 1603 - key invalid for use in specified stat...

    cannot use skype, cannot re-install Skype
    get: error 1603
    and window stating: key invalid for use in specified state
    Skype was working fine up to yesterday (Sept 15 2014)

    ruwim escribió:
    Try to uninstall Windows Security update KB2918614.
    http://community.skype.com/t5/Windows-desktop-client/Error-Key-not-valid-for-use-in-specified-state/​...
    I personally whould not recommend that, because uninstalling the update KB2918614 places the Windows Installer service back to its original design, but also leaves it vulnerable to the reported security issue https://technet.microsoft.com/library/security/MS1​4-049
    more info about this here: http://windowsitpro.com/security/bug-or-feature-kb​2918614-alters-windows-installer-behavior
    so, the right way to solve this this, is fixing user credentials and permissions, that could be corrupted by a virus.
    1 - Reset File Permissions: http://www.tweaking.com/content/page/reset_file_pe​rmissions.html
    2 - Reset Registry Permissions: http://www.tweaking.com/content/page/reset_registr​y_permissions.html
    3 - Repair MSI (Windows Installer): http://www.tweaking.com/content/page/repair_msi_wi​ndows_installer.html
    after that, you can try uninstall KB2918614 and then install KB2918614 again from Windows Update in Control Panel.

  • After my macbook was serviced, when I tried to open CS6, it prompted me to key in the serial number. After keying in, I got error message saying the serial number is invalid. However I have checked that it is correct.

    After my macbook was serviced, when I tried to open CS6, it prompted me to key in the serial number. After keying in, I got error message saying the serial number is invalid. However I have checked that it is correct.

    First be sure login and password are OK. Sometimes the address starts wit "http://..." and sometime starts with "ftp://...". Try both normal FTP access and Scure FTP access (SFTP). At the end, contact the site's provider.

  • Invalid Keystore Format error

    we need to configure an SSO from SAP portal and a third party website by passing encrypted userid as url parameters.
    To configure the SSO I have received the public key of the third party and able to access it from server location. Now I have to access priavte key of the SAP Portal certificate and sign the UserId and pass it as url parameter. I have gone through many blogs and written code as below which is giving Invalid Keystore Format error.
    My question is
    1. What should be passed to FileInputStream?
    As of now we are passing the .cer file which is stored as part of project.
    Below code is throwing error at ks.load() method.
    String fielPath1 = request.getPublicResourcePath()+"/SAPLogonTicketKeypair-cert1.cer";
    FileInputStream ksfis = new FileInputStream(fielPath1);
    KeyStore ks = KeyStore.getInstance("JKS");
    ks.load(null, sPass.toCharArray());
    BufferedInputStream ksbufin = new BufferedInputStream(ksfis);
    ks.load(ksbufin, sPass.toCharArray());
    PrivateKey priv = (PrivateKey) ks.getKey(alias, kPass.toCharArray());
    Error is:
    Invalid keystore formatsun.security.provider.JavaKeyStore.engineLoad(JavaKeyStore.java:633)sun.security.provider.JavaKeyStore$JKS.engineLoad(JavaKeyStore.java:38)java.security.KeyStore.load(KeyStore.java:1185)am_sso_apc.doContent(am_sso_apc.java:132)com.sapportals.portal.prt.component.AbstractPortalComponent.serviceDeprecated(AbstractPortalComponent.java:213)
    Please let me know how to pass the filepath to extract the priavte key .
    Regards,
    Satish

    I found the solution. As follows:
    keytool -list -keytool keytoolfile -storetype jceks

  • Invalid Cursor Position Error on Windows XP using CachedRowSet

    Hello, I don't know if this question lies here, but I thought it would be the well suited place so please pardon me if it isn't. I am trying to access multiple pages from my database on my XP machine but I am getting an "invalid cursor position" error when trying to access the next page. I don't know how this error is coming about because it works well on a Vista machine with no errors. I don't know if it is my drivers or something that brings about the problem. I am using mysql connecter 5.1.10, JRE 1.6.0_02 and windows XP SP2
    Below is a simple code that brings the error.
    package Admin; import javax.sql.rowset.CachedRowSet; import com.sun.rowset.CachedRowSetImpl; public class test { public void table() { try { CachedRowSet crs=new CachedRowSetImpl(); crs.setUrl("jdbc:mysql://host:3306/database");         crs.setUsername("User");         crs.setPassword("password"); crs.setCommand("select * from myTable"); int[] keys = {1}; crs.setKeyColumns(keys); crs.execute(); crs.last(); if(crs.getRow()>500){ //new overLimit(); } crs.setPageSize(3); crs.execute(); while (crs.next()) { System.out.print("page one----"); System.out.println(crs.getString(1)); } while(crs.nextPage()){ System.out.println("page two---"); while (crs.next()) { System.out.println("in page two"); System.out.println(crs.getString(1)); } } } catch (Exception e) { e.printStackTrace(); } } public static void main(String []args){ new test().table(); } }

    Yes I am running the same code on both machines. The output I get on the XP machine is shown below. I modified the code I posted earlier and replaced the "page two" text with "page (then page number)" and also omitted the "in page two" text for better readability---------PAGE 0---------
    DB09140110
    DU35463010
    EX29201810
    ---------PAGE 1---------
    EX38341510
    EX40471810
    KZ280299
    ----------PAGE 2---------
    LA130299
    LC130299
    MC081009
    ----------PAGE 3---------
    RZ300502
    VA130299
    VI020209
    ----------PAGE 4---------
    YX101008
    ZE220299
    ZF231105and vista....
    ----------PAGE 0---------
    EX38341510
    EX40471810
    KZ280299
    ----------PAGE 1---------
    LA130299
    LC130299
    MC081009
    ----------PAGE 2---------
    RZ300502
    VA130299
    VI020209
    ----------PAGE 3---------
    YX101008
    ZE220299
    ZF231105

  • Acrobat Pro V8.1.2 "Invalid Page Range" Error - Rotate Pages

    Hi,
    I have Adobe Acrobat Professional version 8.1.2. For the last couple of weeks every time I try to rotate a page in any direction I get the following error:
    "Invalid Page Range" (OK)
    I have tried every combination of options for amount of rotation and page range (all, selected, specify). No matter what I do I get the same message. I have tried this on several different documents both encrypted and unencrypted.
    Does anyone have any ideas?

    I know this is nearly 4 years late, and I realise this may not have been the cause with the original post, but for the sake of covering this issue for anyone who searches and lands on this page:  The most common cause for receiving this "invalid page range" error when attempting to rotate pages is becaue the option for "Even and Odd Pages," "Even Pages Only," or "Odd Pages Only" drop-down choices are inconsistent with the selection.  For example, if you're trying to rotate just page 1, but the selection "Even Pages Only" is slected, then you will receive this error.  You will find this option in the options window that appears when you click the Rotate command.
    Just my two cents after trying to remedy this over and over with users.
    Cheers!

  • Error while encrypting the xml file using asymmetric cipher...pls help

    i am encryption the xml file using asymmetric cyper....
    in one class , i am generating private key and public key using "RSA" algorithm..using 1024 byte initialization...
    it is generating properly...
    and after that in second class i am encrypting the xml file using "DESede" algorithm and i am using public key of above class..
    but i am getting exceptione :
    java.security.InvalidKeyException: Invalid key length: 162 bytes
    at com.sun.crypto.provider.DESedeCipher.engineGetKeySize(DashoA6275)
    at javax.crypto.Cipher.init(DashoA6275)
    at XmlEncryption.getEncryptedData(XmlEncryption.java:147)
    at XmlEncryption.encryptCompleteXmlFile(XmlEncryption.java:123)
    at demoXmlEncApp.simulateBookSellersEnd(demoXmlEncApp.java:72)
    at demoXmlEncApp.main(demoXmlEncApp.java:29)
    so, what is that ?
    i want to use RSA algo for key generatiion and DESede for cipher initialization .
    is there any site for where source code of xml file encryption using asymmetric cipher is available?
    pls, help me.....

    Sachin,
    What sabre150 is trying to explain to you, is that encrypting data (such as an XML file) is a 2-step process. In the first step, you generate a symmetric key (such as DES, 3DES, AES) and encrypt your file with this key (and the appropriate mode and padding).
    In order to ensure that your encrypted data cannot be decrypted by unauthorized individuals, you now need to protect the symmetric key. Encrypting your symmetric key with another symmetric key does not solve the problem, since you have a chain of symmetric keys that need to be encrypted into infinity.
    Cryptographers solve this problem by encrypting the symmetric key with an asymmetric key, such as as RSA. To perform this second step, you generate an RSA key-pair, encrypt the symmetric key you generated in step 1 with the Public key of the RSA key-pair, and give the recipient of the encrypted XML file, access to the Private key of the RSA key-pair as well as the encrypted symmetric key.
    The recipient, then uses the RSA Private key to decrypt the symmetric key first, and then uses the "plaintext" symmetric key to decrypt the XML file.
    What sabre150 was also attempting to explain to you, is the traditional way of transporting an encrypted "blob" that consists of data + symmetric key. With a modern key-management system, combining the two would be unnecessary.

  • Error during encryption or decryption. System error code 997.

    Hello,
    I am trying to reconnect to a farmafter my PDC crashed and I had to create all the new users, When I run the sharepoint configuration tool and can get as far as entering the DB server which then finds the sharepoint_config. I add the connection details and select next which then throws up the following error:
    09/13/2008 13:20:34  8  INF                              The parameter user is chosen,
    so returning the value as IPIC\cdigby
    09/13/2008 13:20:34  8  INF                              Entering function Command.this[string key]
    09/13/2008 13:20:34  8  INF                                Entering function CommandCollectionBase.Get
    09/13/2008 13:20:34  8  INF                                  Found value in collection for key password
    09/13/2008 13:20:34  8  INF                                Leaving function CommandCollectionBase.Get
    09/13/2008 13:20:34  8  INF                                Found parameter password in collection
    09/13/2008 13:20:34  8  INF                              Leaving function Command.this[string key]
    09/13/2008 13:20:34  8  INF                              The parameter password is chosen, so returning the value as ***************
    09/13/2008 13:20:34  8  INF                              The parameter password is chosen, so returning the value as ***************
    09/13/2008 13:20:34  8  INF                              Entering function Common.CreateSecureSringFrom
    09/13/2008 13:20:34  8  INF                              Leaving function Common.CreateSecureSringFrom
    09/13/2008 13:20:34  8  INF                              Entering function Farm.IsJoinedToFarm
    09/13/2008 13:20:34  8  INF                                Entering function Farm.TryIsJoinedToFarm
    09/13/2008 13:20:34  8  INF                                  My cached Farm object is null, so will load it
    09/13/2008 13:20:34  8  INF                                  Calling SPFarm.Local and SPServer.Local to get the local farm objects
    09/13/2008 13:20:34  8  INF                                  SPFarm.Local returned null.  This usually means that the server is not joined.  But, you can delete a server from the configdb without unjoining, which would mean that this machine still thinks it is joined.
    09/13/2008 13:20:34  8  INF                                  Trying to access the server farm connection string
    09/13/2008 13:20:34  8  INF                                  Entering function TaskCommon.TryGetWssVersion3ConnectionStringExists
    09/13/2008 13:20:34  8  INF                                    Entering function RegistryHelper.RegistryHelper
    09/13/2008 13:20:34  8  INF                                      The RegistryHelper has the key name as SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\12.0\Secure\ConfigDB and the registry hive as LocalMachine
    09/13/2008 13:20:34  8  INF                                    Leaving function RegistryHelper.RegistryHelper
    09/13/2008 13:20:34  8  INF                                    WSS v3 registry key SOFTWARE\Microsoft\Shared Tools\Web Server Extensions\12.0\Secure\ConfigDB for the connection string does not exist
    09/13/2008 13:20:34  8  INF                                    Unable to get the WSS v3 connection string
    09/13/2008 13:20:34  8  INF                                  Leaving function TaskCommon.TryGetWssVersion3ConnectionStringExists
    09/13/2008 13:20:34  8  INF                                  DID NOT discover a v3 connection string and SPFarm.Local indicates that this machine is not joined.
    09/13/2008 13:20:34  8  INF                                  Entering function Farm.Clear
    09/13/2008 13:20:34  8  INF                                    Entering function CentralAdminServiceInstance.Reset
    09/13/2008 13:20:34  8  INF                                    Leaving function CentralAdminServiceInstance.Reset
    09/13/2008 13:20:34  8  INF                                  Leaving function Farm.Clear
    09/13/2008 13:20:34  8  INF                                Leaving function Farm.TryIsJoinedToFarm
    09/13/2008 13:20:34  8  INF                              Leaving function Farm.IsJoinedToFarm
    09/13/2008 13:20:34  8  INF                              Creating connection string for config db SharePoint_Config server IPIC-SERVER2\SHAREPOINT
    09/13/2008 13:20:34  8  INF                              Creating connection string for admin content db SharePoint_AdminContent_938f78c4-0a10-4a04-b4e0-26a95d7a9022 server IPIC-SERVER2\SHAREPOINT
    09/13/2008 13:20:34  8  INF                              Using NTLM for sql connection string
    09/13/2008 13:20:34  8  INF                              Openning configdb so that I can join it at server IPIC-SERVER2\SHAREPOINT database SharePoint_Config in farm mode
    09/13/2008 13:20:34  8  INF                              Now joining to farm at server IPIC-SERVER2\SHAREPOINT database SharePoint_Config
    09/13/2008 13:21:38  8  ERR                              Task configdb has failed with an unknown exception
    09/13/2008 13:21:38  8  ERR                              Exception: System.ArgumentException: Error during encryption or decryption. System error code 997.
       at Microsoft.SharePoint.Administration.SPCredentialManager.DecryptWithMasterKey(Byte[] rgbEncryptedPassphrase)
       at Microsoft.SharePoint.Administration.SPEncryptedString.GetSecureStringValue()
       at Microsoft.SharePoint.Administration.SPEncryptedString.get_SecureStringValue()
       at Microsoft.SharePoint.Administration.SPProcessIdentity.get_SecurePassword()
       at Microsoft.SharePoint.Administration.SPApplicationPool.Provision()
       at Microsoft.SharePoint.Administration.SPWebServiceInstance.Provision()
       at Microsoft.SharePoint.Administration.SPFarm.Join()
       at Microsoft.SharePoint.PostSetupConfiguration.ConfigurationDatabaseTask.CreateOrConnectConfigDb()
       at Microsoft.SharePoint.PostSetupConfiguration.ConfigurationDatabaseTask.Run()
       at Microsoft.SharePoint.PostSetupConfiguration.TaskThread.ExecuteTask()
    If anyone can help me work around this I would be extremly grateful.
    Thanks

       Hi,
    I found an article explaining the issue: http://support.microsoft.com/kb/927156.
    Please try to disconnect the configuration database from existing farm environment, and then create a new configuration database:
    1.      Click Start, click Run, type cmd in the Open box, and then click OK.
    2.      At the command line, change to the following directory: \Program Files\Common Files\Microsoft Shared\web server extensions
          \12\BIN
    3.      At the command prompt, type the following command to create a new configuration database: psconfig -cmd configdb -create -server
         ServerName -database ConfigDBName -user Domain\User -password Password
    4.      Rerun the SharePoint Products and Technologies Wizard.
    Hope it helps.

  • Invalid Flow Context error in Inbound Queues

    I am new to CRM middleware.
    We are getting lot of entries in CRM Inbound Queue (SMQ2) in our production system with error description,
    "Invalid Flow Context".
    The queues are of type, "R3AD_CONNOBJXXXXXXXXXX" and the FM the error was caused in, is "BAPI_CRM_SAVE".
    Can anyone help?
    Thanks in advance!
    Rajiv

    Thanks Rohit,
    When I debugged an entry with this "Invalid Flow Context" error, In method, CRM_GENERIC_CRM_IN, in the call to function, SMOF0_READ_SMOFSUBINT, in read statement,
       read table t_smofsubint binary search
               with key objclass = i_objclass
                        objname  = space.
    I am getting sy-subrc = 4.
    i.e. entries do not exist for SI_POD in table SMOFSUBINT.
    Has this behaviour got anything to do with this error?

  • Help on Merge Statement ,I got 'ORA-00904: invalid column name' Error

    Pls help
    In Oracle 9i i implement the following qry
    MERGE INTO jobs A
    USING (select order_no,jOB_SEQ_NO from jobs_dlt) B
    ON (A.ORDER_NO = B.ORDER_NO and A.JOB_SEQ_NO =B.JOB_SEQ_NO )
    WHEN MATCHED THEN
    UPDATE SET
              A.ORDER_NO= B.ORDER_NO ,
              A.JOB_SEQ_NO= B.JOB_SEQ_NO           
    WHEN NOT MATCHED THEN
    INSERT (
              A.JOB_SEQ_NO ,
              A.ORDER_NO
    VALUES (
              B.JOB_SEQ_NO ,
              B.ORDER_NO
    but i got 'ORA-00904: invalid column name' Error
    JOBS table Contain the above Column
    how i implement the Merge Statment
    Thanks in advance
    By
    Sekar

    I seem to recall this error being spuriously (well unhelpfully) thrown if you tried to UPDATE a key that you used in the ON clause, but I could be mistaken.
    For us to recreate this you would need to supply the exact version and scripts to create the tables in question.

  • Have lightroom 5 hard copy and just got a mac.  downloaded the trial version of LR5 from the web, but it will not take my serial number.  gives me an invalid serial number error

    i have had lightroom 5 for some time now, and have used on my pc.  I just got a mac (no disc drive) so I downloaded the trial version of LR5 from the adobe site.  Once installed, i tried to key in my serial number. 
    I get an invalid serial number error.
    has anyone ran into this before?

    Serial number and activation support (non-CC)
    http://helpx.adobe.com/x-productkb/global/service1.html ( http://adobe.ly/1aYjbSC )

  • Treo 700p: AirSAMStateMachine.c 2438 4 Sync key invalid, cmd: 4, status: 4

    I have a user getting the error "AirSAMStateMachine.c 2438 4 Sync key invalid, cmd: 4, status:4" when he tries to sync contacts on his 700p.  His messages and calendar sync fine, but syncing his contacts does not.
    Post relates to: Centro (Sprint)

    Hello!
    Which software version does the phone have.  Go here to check that out:
    http://kb.palm.com/SRVS/CGI-BIN/WEBCGI.EXE/,/?St=1301,E=0000000000320371400,K=179,Sxi=4,case=obj(931...
    Make sure it is at least 1.10.  If not, please run the updater found there. 
    Post relates to: Treo 650 (Unlocked GSM)
    Post relates to: Treo 650 (Unlocked GSM)

  • How can I fix an invalid sibling link error message without my original install disk?

    How can I fix an invalid sibling link error message without my original install disk?

    Hi Jeff,
    It's not even likely the Install Disc could fix that, but if you want to try...
    Does it boot to Single User Mode, CMD+s keys at bootup, if so try...
    /sbin/fsck -fy
    Repeat until it shows no errors fixed.
    (Space between fsck AND -fy important).
    Resolve startup issues and perform disk maintenance with Disk Utility and fsck...
    http://docs.info.apple.com/article.html?artnum=106214
    You must repair the HD, your best bet is likely DiskWarrior.
    BTW, you might enjoy these DiskWarrior review/recommendations...
    http://discussions.apple.com/thread.jspa?messageID=9645801&#9645801
    http://discussions.apple.com/thread.jspa?messageID=10541019#10541019
    http://discussions.apple.com/thread.jspa?messageID=11918925&#11918925
    http://discussions.apple.com/thread.jspa?messageID=12684129#12684129
    http://discussions.apple.com/thread.jspa?messageID=12744794&#12744794
    http://discussions.apple.com/thread.jspa?messageID=12912879#12912879
    Finally, you should run DiskWarrior if your Mac explicitly warns you of a problem with your disk in the form of an error message. Most of these errors are reported by the built-in Disk Utility whether your Mac OS X version is 10.3 Panther, 10.4 Tiger, 10.5 Leopard, 10.6 Snow Leopard or 10.7 Lion. Here are some of the most common messages:
    Disk Repair: The disk was not repairable by this computer. It is being made available to you with limited functionality. You must back up your data and reformat the disk as soon as possible.
    The underlying task reported failure on exit.
    Invalid node structure.
    Keys out of order.
    Invalid key length.
    Invalid directory item count.
    Invalid extent entry.
    Invalid record count.
    Invalid index key.
    Invalid sibling link.
    http://www.alsoft.com/DiskWarrior/details3.html

  • [svn:fx-4.0.0] 13531: * Fixed invalid property reference error reporting by postponing the

    Revision: 13531
    Revision: 13531
    Author:   [email protected]
    Date:     2010-01-15 12:50:59 -0800 (Fri, 15 Jan 2010)
    Log Message:
    Fixed invalid property reference error reporting by postponing the
      validation until prelink when the MxmlDocument's type is available.
    QE notes:
    Doc notes:
    Bugs: SDK-22995, SDK-24738
    Reviewer: Gaurav, Darrell
    Tests run: checkintests, mxmlcunit
    Is noteworthy for integration: no
    Code-level description of changes:
      modules/compiler/src/java/flex2/compiler_en.properties
        Renamed css.StyleDef.InvalidPropertyReference to
        css.StylesContainer.InvalidPropertyReference.
      modules/compiler/src/java/flex2/compiler/css/StyleDef.java
        Removed InvalidPropertyReference checking from processReference().
      modules/compiler/src/java/flex2/compiler/css/StylesContainer.java
        Modified setMxmlDocument() to store a reference to it's QName.
        Modified validate() to iterate over all style properties and to
        call validatePropertyReferences() if mxmlDocumentQName is not
        null.
    Ticket Links:
        http://bugs.adobe.com/jira/browse/SDK-22995
        http://bugs.adobe.com/jira/browse/SDK-24738
    Modified Paths:
        flex/sdk/branches/4.0.0/modules/compiler/src/java/flex2/compiler/css/StyleDef.java
        flex/sdk/branches/4.0.0/modules/compiler/src/java/flex2/compiler/css/StylesContainer.java
        flex/sdk/branches/4.0.0/modules/compiler/src/java/flex2/compiler_en.properties

    Hi
    yes, I had the same issue and I found a solution.
    You need to request a patch for BUG 9212862 (already corrected in WLS 10.3.3) and do the follwing:
    javax.xml.ws.BindingProvider provider = (javax.xml.ws.BindingProvider)port;
    java.util.Map context = provider.getRequestContext();
    context.put(weblogic.wsee.jaxrpc.WLStub.POLICY_COMPATIBILITY_PREFERENCE, weblogic.wsee.jaxrpc.WLStub.POLICY_COMPATIBILITY_MSFT);      
    This will cause the SecurityMessageArchitect class of WLS to not send the SecurityTokenReference in the Soap security header.
    Please note that is evidently a non-comformity to the specs of microsoft:
    Please give a look at
    http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0.pdf (8.3 Signing Tokens)
    and also at:
    http://www.oasis-open.org/committees/download.php/16768/wss-v1.1-spec-os-SAMLTokenProfile.pdf
    (3.4 Identifying and Referencing Security Tokens)
    A SAML key identifier reference MUST be used for all (local and remote) references to SAML 1.1
    assertions. [...]
    All conformant implementations MUST be able to process SAML assertion references occurring in a
    <wsse:Security> header or in a header element other than a signature to acquire the corresponding
    assertion. A conformant implementation MUST be able to process any such reference independent of the
    confirmation method of the referenced assertion.
    It follows that the .NET 3.5 is a non conformat implementation: I would gladly know which is the position of Microsoft on that.
    ciao
    carlo

Maybe you are looking for