Search Results

Search found 2579 results on 104 pages for 'mike krejci'.

Page 79/104 | < Previous Page | 75 76 77 78 79 80 81 82 83 84 85 86  | Next Page >

  • Security strategies for storing password on disk

    - by Mike
    I am building a suite of batch jobs that require regular access to a database, running on a Solaris 10 machine. Because of (unchangable) design constraints, we are required use a certain program to connect to it. Said interface requires us to pass a plain-text password over a command line to connect to the database. This is a terrible security practice, but we are stuck with it. I am trying to make sure things are properly secured on our end. Since the processing is automated (ie, we can't prompt for a password), and I can't store anything outside the disk, I need a strategy for storing our password securely. Here are some basic rules The system has multiple users. We can assume that our permissions are properly enforced (ie, if a file with a is chmod'd to 600, it won't be publically readable) I don't mind anyone with superuser access looking at our stored password Here is what i've got so far Store password in password.txt $chmod 600 password.txt Process reads from password.txt when it's needed Buffer overwritten with zeros when it's no longer needed Although I'm sure there is a better way.

    Read the article

  • Fixing an SQL where statement that is ugly and confusing

    - by Mike Wills
    I am directly querying the back-end MS SQL Server for a software package. The key field (vehicle number) is defined as alpha though we are entering numeric value in the field. There is only one exception to this, we place an "R" before the number when the vehicle is being retired (which means we sold it or the vehicle is junked). Assuming the users do this right, we should not run into a problem using this method. (Right or wrong isn't the issue here) Fast forward to now. I am trying to query a subset of these vehicle numbers (800 - 899) for some special processing. By doing a range of '800' to '899' we also get 80, 81, etc. If I cast the vehicle number into an INT, I should be able to get the right range. Except that these "R" vehicles are kicking me in the butt now. I have tried where vehicleId not like 'R%' and cast(vehicleId as int) between 800 and 899 however, I get a casting error on one of these "R" vehicles. What does work is where vehicleId not between '800' and '899' and cast(vehicleId as int) between 800 and 899', but I feel there has to be a better way and less confusing way. I have also tried other variations with HAVING and a sub-query all producing a casting error.

    Read the article

  • Co-opt popular abandonware opensource project?

    - by Mike Bouck
    Here's the scenario: A popular open source project is used/loved by many but has become stale due to the fact that the last drop came out nearly a year ago. Many bugs/feature requests/fixes have been logged in the interim and everyone is getting by via downloading the trunk and building custom/private builds with the changes incorporated. The copyright is simple -- there is none and the code is in the public domain. The project owner spins the project as community open source and has set up a sourceforge site, but to date (5 years running now) has yet to accept one contributor. In other words the "community" is a community of one. The project owner takes great pride in the project and has obviously contributed a lot of time/effort but for whatever reason has has seemingly abandoned the project and is unresponsive when offers of help are made. So, the question, should the community fork the codebase, set up a new community site, and take matters in their own hands?

    Read the article

  • Passing null child object from parent object to a partial view

    - by Mike
    I have an object which contains models for my ASP.NET MVC web app. The Model that is being passed into the view has sub models for "gadgets" on that particular view. Each of these sub models gets passed to a partial view (gadget). The problem is when I have a null model in the view model. See example below. View Model: public class FooBarHolder() { public FooBar1 FooBar1 { get; set; } public FooBar2 FooBar2 { get; set; } } We pass FooBarHolder into the view and inside the view we make calls such as <% Html.RenderPartial("Foo", Model.FooBar1); %> <% Html.RenderPartial("Foo2", Model.FooBar2); %> Now say for instance that Model.FooBar2 was null. What I am experiencing from the strongly typed partial view is an error that says "This view expected a model of type FooBar2 but got a model of type FooBarHolder." Why is this happening instead of just passing in a null?

    Read the article

  • Is there a way to capture a bitmap from a WPF window using native C++?

    - by Mike Caron
    Imagine a document window in a MDI application which contains a child WPF window, say a sidebar for example. How can one get a bitmap containing both the WPF pixels AND the GDI (non-wpf) pixels? I've discovered that when making my thumbnail preview for the Win7 taskbar app icon hover, I get black in the parts of the preview where the WPF pixels should be. My current method simply grabs a bitmap capture of the document window. Then I get a DC for the preview, make a memory DC from it and select my bitmap into it. Then I do some size adjustments and bitblt the memory dc to the real dc. I'm guessing that the BitBlt operation doesn't take into account the fact that the WPF pixels are hardware accelerated and therefore need to be grabbed from the graphics hardware. All the stuff in GDI is managed just fine, though and when there's no WPF child windows, the preview image looks fine. I'm wondering if it's at all possible to grab a bitmap of the WPF window from native C++. Then I can blt that onto the black area of the previous preview.

    Read the article

  • Django populate select field based on model query

    - by Mike
    I have the following model class DNS(models.Model): domain = models.ForeignKey(Domain) host_start = models.CharField(max_length=150, blank=True, null=True) type = models.SmallIntegerField(max_length=1, default=0, choices=DNS_CHOICE) value = models.SmallIntegerField(max_length=3, default=0, blank=True, null=True) ip = models.IPAddressField(blank=True, null=True) host_end = models.ForeignKey("DNS", blank=True, null=True) other_end = HostnameField(max_length=150, blank=True, null=True) created = models.DateTimeField(auto_now_add=True) sticky = models.BooleanField(default=0) other = models.BooleanField(default=0) When I try to init a form with just foreignkeys on host_end.. it always shows all entries in the DNS table domain = Domain.objects.get(id=request.GET['domain'], user=request.user, active=1) form = DNSFormCNAME(initial={'ip': settings.MAIN_IP, 'type': request.GET['type'], 'host_end': DNS.objects.filter(domain=domain)}) I just want the zones that match that domain.. not all domains.

    Read the article

  • Use ImageMagick to place an image inside a larger canvas

    - by Mike
    Getting started with ImageMagic and trying to find a way to do this... If an image is less than 50 pixels tall or 50 pixels wide, I'd like to place it (un-scaled) in the horizontal/vertical center of a new 50x50 pixel canvas on top of a white background - and save that as the new image. Anyone know if this is possible with ImageMagick? Thanks!

    Read the article

  • Question about C Pointers (just learning)

    - by Mike
    I am curious as to why this is an error and what the error message means. Here is some code. int *x[] = {"foo", "bar", "baz"}; int *y[] = {"foo", "bar", "baz"}; x = y; I try to compile and I get this: error: incompatible types when assigning to type ‘char [3]’ from type ‘char *’ Question #1 why is this an error? and Question #2 why are the types different? Thanks for you help.

    Read the article

  • Contacts activity doesn't return data

    - by Mike
    In my app I simply open the list of activities and when a contact is clicked I attempt to retrieve the name of the contact selected and put it into a string. The app crashes in the onActivityResult() function. I do have the READ_CONTACTS permission set. /** * Opens the contacts activity */ public void openContacts() { Intent intent = new Intent(Intent.ACTION_PICK, People.CONTENT_URI); startActivityForResult(intent, PICK_CONTACT); } @Override public void onActivityResult(int reqCode, int resultCode, Intent data) { super.onActivityResult(reqCode, resultCode, data); switch (reqCode) { case (PICK_CONTACT) : if (resultCode == Activity.RESULT_OK) { Uri contactData = data.getData(); Cursor c = managedQuery(contactData, null, null, null, null); //NullPointerException thrown here, line 102 if (c.moveToFirst()) { String name = c.getString(c.getColumnIndexOrThrow(People.NAME)); FRIEND_NAME = name; showConfirmDialog(name); } } break; } } The following logcat error logs are returned: Any help is appreciated. Thanks

    Read the article

  • Recursive SQL, have the last three values increased?

    - by Mike
    Hi, I have a table that looks like this: ---------------------- | DateTime | Value | ---------------------- | 2010-01-01 | 26 | | 2010-02-01 | 24 | | 2010-03-01 | 23 | | 2010-04-01 | 28 | | 2010-05-01 | 30 | I need to find if the last three consecutive months have increased in value. How can I get SQL to check whether the value for each has increased? If anyone can give me any pointers for solving this problem it would be greatly appreciated! Thanks

    Read the article

  • Replace always replacing null values

    - by Mike
    Why does left(FIELD, replace(nullif(charindex('-', FIELD), 0), null, len(FIELD))) always return null? The idea behind the query is that if charindex() returns 0, then convert the results into null, then convert the null into the length of the field. So if '-' does not exist, show the whole string. For some reason it makes every row equal null. Thank you.

    Read the article

  • In which situation is the c++/c# namespace approach better than the Java approach?

    - by mike g
    The reason I ask this is that c# could easily have copied the java convention, or a variation of it, but opted for the more flexible approach of explicitly declaring namespaces inside files. As a Java programmer often there are things that I wish I could do differently, but namespaces is not one of them. The flexbility has a certain overhead (extra braces, extra decisions for developers, making it harder to view a projects contributions to the namespace, at least without a specialist IDE). So what practical examples are there when this flexiblity is advantageous?

    Read the article

  • Different RegisterWindowMessage() names appear the same

    - by Mike Trader
    Using the C/C++ Windows API RegisterWindowMessage() I am using the name of the application as the message name. Next I call CreatMutex() using the same name so that I can tell if it already exists. If it does, I know this application is already running and not to launch a second instance of it. THis is the operation of my function Running() My confusion is over the message name. It seems that "AutoConvert.exe" and "AutoAppend.exe" are interpreted as the same name. Why?

    Read the article

  • How to find multiple words on the same line in Notepad++

    - by Mike
    I have a 4MB log file from the Windows XP firewall which I'm trying to find lines that have both DROP and an IP and a port number. My regex-fu is weak and I'm assuming this is the reason I'm struggling. The words "DROP", "10.1.1.1" (for example) and "8801" need to be found on the same line and may be spread across the line and separated by one or more other words. Any help (or suggestions of another method to do this) are much appreciated.

    Read the article

  • unix cut, remove first token

    - by Mike
    I'm trying to use unix cut to remove the first two fields per line. I have input lines of of the form (token)(whitespace)(token)(lots of text) The problem is that there exit n tokens per line, so I can't do something like this cut -f3,4,5,6,7,8,9 is there a way to tell cut to take everything except the specified fields

    Read the article

  • What are the requirements to consider someone as a Software Engineer? Is it just a job title? [close

    - by mike
    I am employed as a Software Engineer with a background in C# and .NET. I am trying to interface with an web API. I asked for help because I didn't know to connect to it or handle the results. Someone told me that I shouldn't consider myself a Software Engineer because I didn't know to how to do it. They said the API was well documented, required no authentication, and returned XML that I could easily parse. They said the documentation should be enough to figure out how to use the API. Isn't having a job title of Software Engineer the only consideration for being a Software Engineer?

    Read the article

  • Calling super()

    - by Mike
    When do you call super() in Java? I see it in some constructors of the derived class, but isn't the constructors for each of the parent class called automatically? Why would you need to use super?

    Read the article

  • Perl, foreach order

    - by Mike
    Does Perl's foreach loop operator require that the list items be presented in order? For example my @a=(1,2,3); foreach my $item (@a) { print $item; } will always print 1 2 3? I suspect so, but I can't find it documented.

    Read the article

  • Browser, upload large file

    - by Mike
    I'm looking for a way to allow a user to upload a large file (~1gb) to my unix server using a web page and browser. There are a lot of examples that illustrate how to do this with a traditional post request, however this doesn't seem like a good idea when the file is this large. I'm looking for recommendations on the best approach. Bonus points if the method includes a way of providing progress information to the user. For now security is not a major concern, as most users who will be using the service can be trusted. We can also assume that the connection between client and host will not be interrupted (or if it is they have to start over).

    Read the article

  • pass custom environment variables to System.Diagnostics.Process

    - by Mike Ruhlin
    I'm working on an app that invokes external processes like so: ProcessStartInfo startInfo = new ProcessStartInfo(PathToExecutable, Arguments){ ErrorDialog = false, RedirectStandardError = true, RedirectStandardOutput = true, UseShellExecute = false, CreateNoWindow = true, WorkingDirectory = WorkingDirectory }; using (Process process = new Process()) { process.StartInfo = startInfo; process.Start(); process.BeginErrorReadLine(); process.BeginOutputReadLine(); process.WaitForExit(); return process.ExitCode; } One of the processes I'm calling depends on an environment variable that I'd rather not require my users to set. Is there any way to modify the environment variables that get sent to the external process? Ideally I'd be able to make them visible only to the process that's running, but if I have to programmatically set them system-wide, I'll settle for that (but, would UAC force me to run as administrator to do that?) ProcessStartInfo.EnvironmentVariables is read only, so a lot of help that is...

    Read the article

  • Quick to develop web app in Java

    - by Mike Q
    Hi all, I need to develop a basic web app very quickly (1 week) for a demo. My requirements are Java (I need to make use of existing Java libraries to access the relevant data) 2 screens One for static data view, maybe some search parameters Other for basic form entry No fancy AJAX required Ideally easy for a web designer to come in and tart it up as necessary, without having to rewrite everything My first stop was going to be to checkout Wicket as I've heard good things about it. I don't have the time right now to dive into anything heavy, which probably writes off JSF in my mind (I played with JSF1, steep learning curve which I've now slid back down). I'm happy to treat the result as throwaway so if there's a framework which starts of well but then doesn't scale up to bigger projects, that would be ok. Any suggestions appreciated on frameworks/approach.

    Read the article

  • Update database using restful ASP.NET MVC 1.0

    - by Mike
    We are building an MVC 1.0 application right now and using Linq - SQL for our DAL. Following the restful approach we have multiple action events depending on if you are updating or loading or what not. The two that I'm concerned with at this point are the edit and update action methods. Here is the signatures. public ActionResult Update(int customerId, int Id, AggregateModel viewModel) public ActionResult Edit(int customerId, int Id, AggregateModel viewModel) So the idea is that in the Edit method we load up our viewModel and pass it to the view. The user makes changes to the model and then posts back to the Update method. The first thing I could think of to do would be to get the viewModel from the database again, copy the changes in one by one from the posted back model and then submit it back. This would work but does seem clunky to me. What is the best way to insert those changes into the database at this point?

    Read the article

  • How can I determine the "correct" number of steps in a questionnaire where branching is used?

    - by Mike Kingscott
    I have a potential maths / formula / algorithm question which I would like help on. I've written a questionnaire application in ASP.Net that takes people through a series of pages. I've introduced conditional processing, or branching, so that some pages can be skipped dependent on an answer, e.g. if you're over a certain age, you will skip the page that has Teen Music Choice and go straight to the Golden Oldies page. I wish to display how far along the questionnaire someone is (as a percentage). Let's say I have 10 pages to go through and my first answer takes me straight to page 9. Technically, I'm now 90% of the way through the questionnaire, but the user can think of themselves as being on page 2 of 3: the start page (with the branching question), page 9, then the end page (page 10). How can I show that I'm on 66% and not 90% when I'm on page 9 of 10? For further information, each Page can have a number of questions on that can have one or more conditions on them that will send the user to another page. By default, the next page will be the next one in the collection, but that can be over-ridden (e.g. entire sets of pages can be skipped). Any thoughts? :-s

    Read the article

< Previous Page | 75 76 77 78 79 80 81 82 83 84 85 86  | Next Page >