Changeset 2639


Ignore:
Timestamp:
Feb 9, 2011, 7:31:35 PM (11 years ago)
Author:
Tim Podeszwa
Message:

Animation tab modified
animation bug fixed

Location:
trunk/CrypPlugins/WebService
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypPlugins/WebService/DecryptionAnimation.cs

    r2635 r2639  
    7979                    this.presentation._animationStepsTextBox.Text += "\n Encrypt Key";
    8080                    this.presentation._animationStepsTextBox.Text += "\n -> find EncryptionMethod";
    81                     this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     81                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     82                    {
     83                        this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     84                    }
    8285                    this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "EncryptionMethod", 1).BringIntoView();
    8386                    this.animateFoundElements(this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "EncryptionMethod", 1), this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "/xenc:EncryptionMethod", 1));
     
    8689                case 3:
    8790                    this.presentation._animationStepsTextBox.Text += "\n -> Get information about the key to decrypt the encrypted key";
    88                     this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     91                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     92                    {
     93                        this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     94                    }
    8995                    this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "KeyInfo", 1).BringIntoView();
    9096                    this.animateFoundElements(this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "KeyInfo", 1), this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "/ds:KeyInfo", 1));
    9197                    this.presentation._animationStepsTextBox.Text += "\n The information shows that the key was encrypted mit the Web Service public key";
    92                     this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     98                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     99                    {
     100                        this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     101                    }
    93102                    status++;
    94103                    break;
    95104                case 4:
    96105                    this.presentation._animationStepsTextBox.Text += "\n ->  Get the cipher data";
    97                     this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
    98                     this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "CipherData", 1).BringIntoView();
     106                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     107                    {
     108                        this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     109                    }
     110                        this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "CipherData", 1).BringIntoView();
    99111                    this.animateFoundElements(this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "CipherData", 1), this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "/xenc:CipherData", 1));
    100112                    status++;
     
    102114                case 5:
    103115                    this.presentation._animationStepsTextBox.Text += "\n ->  Get the cipher value inside cipher data";
    104                     this.presentation._animationStepsTextBox.Text += "\n ->  which represents the encrypted key";
     116                    this.presentation._animationStepsTextBox.Text += "\n ->  which represents the encrypted key";
     117                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     118                    {
    105119                    this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     120                   
     121                    }
    106122                    this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "CipherValue", 1).BringIntoView();
    107123                    this.animateFoundElements(this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "CipherValue", 1), this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "/xenc:CipherValue", 1));
     
    111127                    this.presentation._animationStepsTextBox.Text += "\n -> Decrypt the encrypted key";
    112128                    this.presentation._animationStepsTextBox.Text += "\n -> Get the reference list which shows";
    113                     this.presentation._animationStepsTextBox.Text += "\n -> which data was encrypted with the encrypted key";
    114                     this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
    115                     this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "ReferenceList", 1).BringIntoView();
     129                    this.presentation._animationStepsTextBox.Text += "\n -> which data was encrypted with the encrypted key";
     130                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     131                    {
     132                        this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     133                    }
     134                        this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "ReferenceList", 1).BringIntoView();
    116135                    this.animateFoundElements(this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "ReferenceList", 1), this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "/xenc:ReferenceList", 1));
    117136                    status++;
     
    119138                case 7:
    120139                    this.presentation._animationStepsTextBox.Text += "\n -> Get the reference";
    121                     this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
    122                     this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "DataReference", 1).BringIntoView();
     140                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     141                    {
     142                        this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     143                    }
     144                        this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "DataReference", 1).BringIntoView();
    123145                    this.animateFoundElements(this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "DataReference", 1), this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "/xenc:DataReference", 1));
    124146
     
    128150                case 8:
    129151                    this.presentation._animationStepsTextBox.Text += "\n -> Get the referenced data";
    130                     this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
    131                     TreeViewItem dataReference = this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "DataReference", 1);
     152                    if (this.presentation._animationStepsTextBox.LineCount > 0)
     153                    {
     154                        this.presentation._animationStepsTextBox.ScrollToLine(this.presentation._animationStepsTextBox.LineCount - 1);
     155                    }
     156                        TreeViewItem dataReference = this.findItem((TreeViewItem)this.encryptedKeyTreeviewElements[actualEncryptedKeyNumber], "DataReference", 1);
    132157                    dataReference.BringIntoView();
    133158                    StackPanel tempHeader1 = (StackPanel)dataReference.Header;
  • trunk/CrypPlugins/WebService/SignatureValidator.cs

    r2635 r2639  
    9393                    try
    9494                    {
    95                         this.DercryptSingleXmlElement(tempElement);
     95                       string decryptedElement = this.DercryptSingleXmlElement(tempElement);
    9696                    }
    9797                    catch (Exception e)
  • trunk/CrypPlugins/WebService/WebServicePresentation.xaml

    r2631 r2639  
    22    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    33    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    4    Height="Auto" Width="Auto" MinWidth="640" MinHeight="480" mc:Ignorable="d" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" d:DesignHeight="480" d:DesignWidth="640">
    5     <Grid Height="470" Width="654">
     4   Height="Auto" Width="Auto" MinWidth="640" MinHeight="480" mc:Ignorable="d" xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" d:DesignHeight="480" d:DesignWidth="668">
     5    <Grid Height="470" Width="664">
    66        <Slider Height="38.341" Margin="0,0,5,0" Name="slider1" VerticalAlignment="Top" IsSelectionRangeEnabled="False" IsMoveToPointEnabled="False" IsDirectionReversed="False" ValueChanged="slider1_ValueChanged" HorizontalAlignment="Right" Width="221.711" />
    77        <TabControl Name="tabControl1" BorderBrush="Transparent" Background="AliceBlue" Margin="8,5,12,0">
     
    2424            </TabItem>
    2525            <TabItem IsSelected="True" Name="_animationTab" Header="Animation" Background="AliceBlue">
    26                 <Grid Height="425" Width="626">
     26                <Grid Height="430" Width="629">
    2727                    <Grid.ColumnDefinitions>
    28                         <ColumnDefinition Width="356" />
    29                         <ColumnDefinition Width="21" />
    30                         <ColumnDefinition Width="216" />
    31                         <ColumnDefinition Width="15*" />
     28                        <ColumnDefinition Width="336*"/>
     29                        <ColumnDefinition Width="5"/>
     30                        <ColumnDefinition Width="277*"/>
    3231                    </Grid.ColumnDefinitions>
    33                     <TreeView Name="_animationTreeView" ScrollViewer.VerticalScrollBarVisibility="Visible" ScrollViewer.HorizontalScrollBarVisibility="Visible" HorizontalAlignment="Stretch" Height="Auto" Margin="0,0,0,-5" VerticalContentAlignment="Stretch" Grid.ColumnSpan="2" />
    34                     <Button HorizontalAlignment="Center" Margin="126,0,16,5" Name="resetButton" Width="75" Height="23.338" VerticalAlignment="Bottom" Click="resetButton_Click" Grid.Column="2" VerticalContentAlignment="Bottom">Reset</Button>
    35                     <TextBox Margin="16,7,0,35" Name="_animationStepsTextBox" HorizontalAlignment="Left" Width="215" TextWrapping="WrapWithOverflow" VerticalScrollBarVisibility="Auto" VerticalContentAlignment="Center" Grid.Column="2" VerticalAlignment="Top" Height="390" Grid.ColumnSpan="2" />
    36                     <Button Height="23" HorizontalAlignment="Center" Margin="34,0,108,4" Name="button1" VerticalAlignment="Bottom" Width="75" Click="button1_Click_3" Grid.Column="2" VerticalContentAlignment="Bottom">Play</Button>
     32
     33                    <TreeView Name="_animationTreeView" ScrollViewer.VerticalScrollBarVisibility="Visible" ScrollViewer.HorizontalScrollBarVisibility="Visible" Margin="0,0,6,0" />
     34                    <GridSplitter HorizontalAlignment="Right" VerticalAlignment="Stretch"  Grid.Column="1" ResizeBehavior="PreviousAndNext"   Width="5" Background="#FFBCBCBC"/>
     35
     36
     37                    <TextBox  Name="_animationStepsTextBox" Grid.Column="2" Margin="6,0,6,69" />
     38                    <Canvas Grid.Column="2" Margin="31,374,38,0">
     39                        <Button Height="23" Name="button1" Width="75" Click="button1_Click_3" VerticalContentAlignment="Center" Canvas.Left="21" Canvas.Top="17" HorizontalAlignment="Center">Play</Button>
     40                        <Button Name="resetButton" Width="75" Height="23.338" Click="resetButton_Click" VerticalContentAlignment="Center" Canvas.Left="120" Canvas.Top="17" HorizontalAlignment="Center">Reset</Button>
     41                    </Canvas>
     42
    3743                </Grid>
    3844            </TabItem>
    3945            <TabItem Name="_securityTraceTab" IsSelected="True" Header="WS-Security Trace" Background="AliceBlue">
    40                 <TextBox Name="txtTrace" FontFamily="Courier New" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" Width="Auto" />
     46               
     47                    <TextBox Name="txtTrace" FontFamily="Courier New" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Auto" Width="Auto" />
     48               
    4149            </TabItem>
    4250        </TabControl>
Note: See TracChangeset for help on using the changeset viewer.